From 5408fd81015f646e1f95f0d7104e73da35cf6c39 Mon Sep 17 00:00:00 2001 From: Aryadev Chavali Date: Fri, 6 Feb 2026 06:05:26 +0000 Subject: [PATCH] main: put stream_stop before FILE pointer close As stream_stop requires a valid FILE pointer (fseek), we need to do it before we close the pipe. --- src/main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main.c b/src/main.c index 289ebe8..2529e4b 100644 --- a/src/main.c +++ b/src/main.c @@ -69,9 +69,9 @@ int main(int argc, char *argv[]) LOG("[INFO]: Initialised stream for `%s`\n", stream.name); end: + stream_stop(&stream); if (pipe) fclose(pipe); - stream_stop(&stream); return ret; }