From e3cb62ffec208b707cf2beb216098d1c68bab40b Mon Sep 17 00:00:00 2001 From: fyodor Date: Sat, 11 Aug 2007 05:36:05 +0000 Subject: [PATCH] merge soc07 r5116 - Flush LOG_NORMAL in gh_perror() and pfatal() instead of LOG_STDOUT when --log-errors is used --- nmap_error.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/nmap_error.cc b/nmap_error.cc index ff32d8a17..cb643a207 100644 --- a/nmap_error.cc +++ b/nmap_error.cc @@ -167,7 +167,7 @@ void pfatal(const char *err, ...) { log_write(o.log_errors? LOG_NORMAL|LOG_STDERR : LOG_STDERR, ": %s (%d)\n", strerror(errno), errno); #endif /* WIN32 perror() compatability switch */ - if (o.log_errors) log_flush(LOG_STDOUT); + if (o.log_errors) log_flush(LOG_NORMAL); fflush(stderr); exit(1); } @@ -204,7 +204,7 @@ void gh_perror(const char *err, ...) { log_write(o.log_errors? LOG_NORMAL|LOG_STDERR : LOG_STDERR, ": %s (%d)\n", strerror(errno), errno); #endif /* WIN32 perror() compatability switch */ - if (o.log_errors) log_flush(LOG_STDOUT); + if (o.log_errors) log_flush(LOG_NORMAL); fflush(stderr); return; }