aboutsummaryrefslogtreecommitdiff
path: root/linux-user/main.c
diff options
context:
space:
mode:
authorBlue Swirl <blauwirbel@gmail.com>2012-06-03 16:35:32 +0000
committerBlue Swirl <blauwirbel@gmail.com>2012-06-21 18:45:18 +0000
commiteeacee4d8652d7f3b9224cfe0707c0ed87cc0e96 (patch)
tree124da0ad9aa9593d6e3333ac0f9ef86a377491b6 /linux-user/main.c
parent5726c27fa913296aafab9f50b912cea5b3709271 (diff)
qemu-log: cleanup
Don't use global variables directly but via accessor functions. Rename globals. Convert macros to functions, add GCC format attributes. Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
Diffstat (limited to 'linux-user/main.c')
-rw-r--r--linux-user/main.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/linux-user/main.c b/linux-user/main.c
index 49108b81d3..d0e0e4fc6a 100644
--- a/linux-user/main.c
+++ b/linux-user/main.c
@@ -1306,8 +1306,9 @@ do { \
fprintf(stderr, fmt , ## __VA_ARGS__); \
cpu_dump_state(env, stderr, fprintf, 0); \
qemu_log(fmt, ## __VA_ARGS__); \
- if (logfile) \
+ if (qemu_log_enabled()) { \
log_cpu_state(env, 0); \
+ } \
} while (0)
static int do_store_exclusive(CPUPPCState *env)