From 82581aa9e46970593888a913bc68fbf9d95bd85b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=8E=E9=80=9A=E6=B4=B2?= Date: Mon, 4 Dec 2023 15:10:58 +0800 Subject: [PATCH] Processing: increase buffer size --- src/common/processing_linux.c | 4 ++-- src/common/processing_windows.c | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/common/processing_linux.c b/src/common/processing_linux.c index 2355eeaca..fe312e587 100644 --- a/src/common/processing_linux.c +++ b/src/common/processing_linux.c @@ -11,7 +11,7 @@ #include #include -#define FF_PIPE_BUFSIZ 4096 +enum { FF_PIPE_BUFSIZ = 8192 }; static inline void waitpid_wrapper(const pid_t* pid) { @@ -52,7 +52,7 @@ const char* ffProcessAppendOutput(FFstrbuf* buffer, char* const argv[], bool use //Child if(childPid == 0) { - int nullFile = open("/dev/null", O_WRONLY|O_CLOEXEC); + int nullFile = open("/dev/null", O_WRONLY | O_CLOEXEC); dup2(pipes[1], useStdErr ? STDERR_FILENO : STDOUT_FILENO); dup2(nullFile, useStdErr ? STDOUT_FILENO : STDERR_FILENO); setenv("LANG", "C", 1); diff --git a/src/common/processing_windows.c b/src/common/processing_windows.c index 5f44d5210..398194b34 100644 --- a/src/common/processing_windows.c +++ b/src/common/processing_windows.c @@ -4,7 +4,7 @@ #include -enum { FF_PIPE_BUFSIZ = 4096 }; +enum { FF_PIPE_BUFSIZ = 8192 }; const char* ffProcessAppendOutput(FFstrbuf* buffer, char* const argv[], bool useStdErr) {