diff options
author | Richard Henderson <richard.henderson@linaro.org> | 2022-04-17 11:30:08 -0700 |
---|---|---|
committer | Richard Henderson <richard.henderson@linaro.org> | 2022-04-20 10:51:11 -0700 |
commit | 905c78fe6066975c096e399d7e180098a618ba61 (patch) | |
tree | 937197248bae00f24c3908c72a7220d925099904 /bsd-user | |
parent | 144539d3605ed7da9b8c1d69f49a282f8c4348b8 (diff) | |
download | qemu-905c78fe6066975c096e399d7e180098a618ba61.zip qemu-905c78fe6066975c096e399d7e180098a618ba61.tar.gz qemu-905c78fe6066975c096e399d7e180098a618ba61.tar.bz2 |
bsd-user: Use qemu_set_log_filename_flags
Perform all logfile setup in one step.
Reviewed-by: Alex Bennée <alex.bennee@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Message-Id: <20220417183019.755276-29-richard.henderson@linaro.org>
Diffstat (limited to 'bsd-user')
-rw-r--r-- | bsd-user/main.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/bsd-user/main.c b/bsd-user/main.c index ed26fc5..aa13eae 100644 --- a/bsd-user/main.c +++ b/bsd-user/main.c @@ -405,16 +405,16 @@ int main(int argc, char **argv) } /* init debug */ - qemu_set_log_filename(log_file, &error_fatal); - if (log_mask) { - int mask; - - mask = qemu_str_to_log_mask(log_mask); - if (!mask) { - qemu_print_log_usage(stdout); - exit(1); + { + int mask = 0; + if (log_mask) { + mask = qemu_str_to_log_mask(log_mask); + if (!mask) { + qemu_print_log_usage(stdout); + exit(1); + } } - qemu_set_log(mask, &error_fatal); + qemu_set_log_filename_flags(log_file, mask, &error_fatal); } if (optind >= argc) { |