aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard Henderson <richard.henderson@linaro.org>2022-04-17 11:29:45 -0700
committerRichard Henderson <richard.henderson@linaro.org>2022-04-20 10:51:11 -0700
commit229ef2eb440d92df1bb663b45e57c3e3008aae13 (patch)
tree9abf83a6506df3420011eb7bbc3bbc9d14fd38b5
parentc5955f4ff4689b7a04cf0a1109fa97ce885876b4 (diff)
os-posix: Use qemu_log_enabled
Do not reference qemu_logfile directly; use the predicate provided by qemu/log.h. Reviewed-by: Alex Bennée <alex.bennee@linaro.org> Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Signed-off-by: Richard Henderson <richard.henderson@linaro.org> Message-Id: <20220417183019.755276-6-richard.henderson@linaro.org>
-rw-r--r--os-posix.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/os-posix.c b/os-posix.c
index ee765f047d..faf6e6978b 100644
--- a/os-posix.c
+++ b/os-posix.c
@@ -291,7 +291,7 @@ void os_setup_post(void)
dup2(fd, 0);
dup2(fd, 1);
/* In case -D is given do not redirect stderr to /dev/null */
- if (!qemu_logfile) {
+ if (!qemu_log_enabled()) {
dup2(fd, 2);
}