Mercurial > dovecot > original-hg > dovecot-1.2
changeset 5042:c14b0e20ff63 HEAD
If we can't open the log file, write the error to stderr instead of relying
on the existing fatal handler which may not do anything.
author | Timo Sirainen <tss@iki.fi> |
---|---|
date | Fri, 19 Jan 2007 20:25:53 +0200 |
parents | aa0927730b5c |
children | 6eb476100897 |
files | src/lib/failures.c |
diffstat | 1 files changed, 3 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/src/lib/failures.c Fri Jan 19 18:33:57 2007 +0200 +++ b/src/lib/failures.c Fri Jan 19 20:25:53 2007 +0200 @@ -347,8 +347,9 @@ else { *file = fopen(path, "a"); if (*file == NULL) { - i_fatal_status(FATAL_LOGOPEN, - "Can't open log file %s: %m", path); + fprintf(stderr, "Can't open log file %s: %s", + path, strerror(errno)); + exit(FATAL_LOGOPEN); } fd_close_on_exec(fileno(*file), TRUE); }