From: Ben Pfaff Date: Sat, 6 Mar 2010 19:43:42 +0000 (-0800) Subject: terminal UI: Fix circumstances when errors should be logged to stdout. X-Git-Tag: sav-api~365 X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?p=pspp;a=commitdiff_plain;h=fddfbb3c47fe4234453350df5b4559d75c3bedc9 terminal UI: Fix circumstances when errors should be logged to stdout. The logic here was supposed to be that, if errors weren't already being logged explicitly and if no output driver was already directed to stdout, then send errors to standard output. But one of the conditions was reversed. This fixes the problem. --- diff --git a/src/ui/terminal/terminal-opts.c b/src/ui/terminal/terminal-opts.c index 7b30ed5fd4..d1296a3625 100644 --- a/src/ui/terminal/terminal-opts.c +++ b/src/ui/terminal/terminal-opts.c @@ -335,7 +335,7 @@ terminal_opts_done (struct terminal_opts *to, int argc, char *argv[]) register_output_driver (to); } - if (to->has_terminal_driver && !to->has_error_file) + if (!to->has_terminal_driver && !to->has_error_file) msglog_create ("-"); string_map_destroy (&to->options);