From 5cc69350f4aacd11f87aee0b7d03993e98bdd3da Mon Sep 17 00:00:00 2001 From: Joshua Sled Date: Sat, 10 Feb 2007 20:05:56 +0000 Subject: [PATCH] Better handling of NULL filename. git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@15556 57a11ea4-9604-0410-9ed3-97b8803252fd --- lib/libqof/qof/qoflog.c | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/lib/libqof/qof/qoflog.c b/lib/libqof/qof/qoflog.c index b3b52eac87..cbde439af5 100644 --- a/lib/libqof/qof/qoflog.c +++ b/lib/libqof/qof/qoflog.c @@ -131,12 +131,7 @@ qof_log_init_filename(const gchar* log_filename) if (log_table == NULL) log_table = g_hash_table_new(g_str_hash, g_str_equal); - // don't prevent multiple qof_log_init() calls to screw this up. - if (!log_filename && fout == NULL) - { - fout = stderr; - } - else + if (log_filename) { int fd; gchar *fname; @@ -172,7 +167,7 @@ qof_log_shutdown (void) if (fout && fout != stderr && fout != stdout) { fclose(fout); - fout == NULL; + fout = NULL; } if (function_buffer)