mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-16 06:31:51 -06:00
qemu-log: introduce qemu_log_separate
In some cases, the same message is printed both on stderr and in the log. Avoid duplicate output in the default case where stderr _is_ the log, and standardize this to stderr+log where it used to use stdio+log. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
This commit is contained in:
parent
31e38a22a0
commit
013a29424c
8 changed files with 43 additions and 27 deletions
|
@ -28,6 +28,13 @@ static inline bool qemu_log_enabled(void)
|
|||
return qemu_logfile != NULL;
|
||||
}
|
||||
|
||||
/* Returns true if qemu_log() will write somewhere else than stderr
|
||||
*/
|
||||
static inline bool qemu_log_separate(void)
|
||||
{
|
||||
return qemu_logfile != NULL && qemu_logfile != stderr;
|
||||
}
|
||||
|
||||
#define CPU_LOG_TB_OUT_ASM (1 << 0)
|
||||
#define CPU_LOG_TB_IN_ASM (1 << 1)
|
||||
#define CPU_LOG_TB_OP (1 << 2)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue