about summary refs log tree commit diff stats
path: root/src
diff options
context:
space:
mode:
authorptitSeb <sebastien.chev@gmail.com>2023-05-01 15:43:47 +0200
committerptitSeb <sebastien.chev@gmail.com>2023-05-01 15:43:47 +0200
commitcbf71f678aea5ebb463daded486a45a267647be2 (patch)
tree42e6a56d288e283ecf22559ae5008b6b9d02e821 /src
parentc983418cb3a1a711013bc8026ac9ecd309092233 (diff)
downloadbox64-cbf71f678aea5ebb463daded486a45a267647be2.tar.gz
box64-cbf71f678aea5ebb463daded486a45a267647be2.zip
Change default log value only if stdout is redirected, not box log output
Diffstat (limited to 'src')
-rwxr-xr-xsrc/main.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main.c b/src/main.c
index 63894b5b..31884fcc 100755
--- a/src/main.c
+++ b/src/main.c
@@ -390,7 +390,7 @@ void LoadLogEnv()
     }
     // grab BOX64_TRACE_FILE envvar, and change %pid to actual pid is present in the name
     openFTrace(NULL);
-    box64_log = ftrace_name?LOG_INFO:(isatty(fileno(ftrace))?LOG_INFO:LOG_NONE); //default LOG value different if stdout is redirected or not
+    box64_log = ftrace_name?LOG_INFO:(isatty(fileno(stdout))?LOG_INFO:LOG_NONE); //default LOG value different if stdout is redirected or not
     p = getenv("BOX64_LOG");
     if(p) {
         if(strlen(p)==1) {