Mercurial > dovecot > original-hg > dovecot-1.2
changeset 1000:0fbafade2d85 HEAD
If auth/login process died unexpectedly, the exit status or killing signal
wasn't logged.
author | Timo Sirainen <tss@iki.fi> |
---|---|
date | Tue, 21 Jan 2003 09:58:49 +0200 |
parents | 070aee0e5b9f |
children | fb9c95a8847f |
files | src/master/auth-process.c src/master/common.h src/master/login-process.c src/master/main.c |
diffstat | 4 files changed, 13 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- a/src/master/auth-process.c Tue Jan 21 09:42:33 2003 +0200 +++ b/src/master/auth-process.c Tue Jan 21 09:58:49 2003 +0200 @@ -160,8 +160,10 @@ struct auth_process **pos; struct waiting_request *next; - if (!p->initialized) - i_fatal("Auth process died too early - shutting down"); + if (!p->initialized) { + i_error("Auth process died too early - shutting down"); + io_loop_stop(ioloop); + } for (pos = &processes; *pos != NULL; pos = &(*pos)->next) { if (*pos == p) {
--- a/src/master/common.h Tue Jan 21 09:42:33 2003 +0200 +++ b/src/master/common.h Tue Jan 21 09:58:49 2003 +0200 @@ -18,6 +18,7 @@ PROCESS_TYPE_MAX }; +extern struct ioloop *ioloop; extern struct hash_table *pids; extern int null_fd, imap_fd, imaps_fd;
--- a/src/master/login-process.c Tue Jan 21 09:42:33 2003 +0200 +++ b/src/master/login-process.c Tue Jan 21 09:58:49 2003 +0200 @@ -223,8 +223,10 @@ return; p->destroyed = TRUE; - if (!p->initialized) - i_fatal("Login process died too early - shutting down"); + if (!p->initialized) { + i_error("Login process died too early - shutting down"); + io_loop_stop(ioloop); + } if (p->listening) listening_processes--;
--- a/src/master/main.c Tue Jan 21 09:42:33 2003 +0200 +++ b/src/master/main.c Tue Jan 21 09:58:49 2003 +0200 @@ -28,9 +28,9 @@ }; static const char *configfile = SYSCONFDIR "/" PACKAGE ".conf"; -static struct ioloop *ioloop; static struct timeout *to; +struct ioloop *ioloop; struct hash_table *pids; int null_fd, imap_fd, imaps_fd; @@ -259,6 +259,9 @@ if (lib_signal_kill != 0) i_warning("Killed with signal %d", lib_signal_kill); + /* make sure we log if child processes died unexpectedly */ + timeout_handler(NULL, NULL); + login_processes_deinit(); auth_processes_deinit(); ssl_deinit();