changeset 11626:c9e8144974f1 HEAD

lib-master: MASTER_SERVICE_FLAG_NO_IDLE_DIE wasn't actually working.
author Timo Sirainen <tss@iki.fi>
date Thu, 24 Jun 2010 15:47:13 +0100
parents c5e78bd1d758
children 661b2138cb7b
files src/lib-master/master-service.c
diffstat 1 files changed, 4 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/src/lib-master/master-service.c	Thu Jun 24 15:13:26 2010 +0100
+++ b/src/lib-master/master-service.c	Thu Jun 24 15:47:13 2010 +0100
@@ -58,8 +58,10 @@
 			  si->si_signo, dec2str(si->si_pid),
 			  dec2str(si->si_uid),
 			  lib_signal_code_to_str(si->si_signo, si->si_code));
-	} else if ((service->flags & (MASTER_SERVICE_FLAG_STANDALONE |
-				      MASTER_SERVICE_FLAG_NO_IDLE_DIE)) == 0) {
+	} else if ((service->flags & MASTER_SERVICE_FLAG_NO_IDLE_DIE) != 0) {
+		/* never die when idling */
+		return;
+	} else if ((service->flags & MASTER_SERVICE_FLAG_STANDALONE) == 0) {
 		/* SIGINT came from master. die only if we're not handling
 		   any clients currently. */
 		if (service->master_status.available_count !=