5fb73d
diff -up dovecot-2.2.9/src/lib-master/master-service.c.fixit dovecot-2.2.9/src/lib-master/master-service.c
5fb73d
--- dovecot-2.2.9/src/lib-master/master-service.c.fixit	2013-11-24 14:37:39.000000000 +0100
5fb73d
+++ dovecot-2.2.9/src/lib-master/master-service.c	2013-11-27 17:52:48.802843395 +0100
5fb73d
@@ -559,6 +559,11 @@ const char *master_service_get_name(stru
5fb73d
 	return service->name;
5fb73d
 }
5fb73d
 
5fb73d
+const enum master_service_flags master_service_get_flags(struct master_service *service)
5fb73d
+{
5fb73d
+	return service->flags;
5fb73d
+}
5fb73d
+
5fb73d
 void master_service_run(struct master_service *service,
5fb73d
 			master_service_connection_callback_t *callback)
5fb73d
 {
5fb73d
diff -up dovecot-2.2.9/src/lib-master/master-service.h.fixit dovecot-2.2.9/src/lib-master/master-service.h
5fb73d
--- dovecot-2.2.9/src/lib-master/master-service.h.fixit	2013-11-24 14:37:39.000000000 +0100
5fb73d
+++ dovecot-2.2.9/src/lib-master/master-service.h	2013-11-27 17:53:05.329705614 +0100
5fb73d
@@ -134,6 +134,8 @@ const char *master_service_get_version_s
5fb73d
 /* Returns name of the service, as given in name parameter to _init(). */
5fb73d
 const char *master_service_get_name(struct master_service *service);
5fb73d
 
5fb73d
+const enum master_service_flags master_service_get_flags(struct master_service *service);
5fb73d
+
5fb73d
 /* Start the service. Blocks until finished */
5fb73d
 void master_service_run(struct master_service *service,
5fb73d
 			master_service_connection_callback_t *callback)
5fb73d
diff -up dovecot-2.2.9/src/ssl-params/main.c.fixit dovecot-2.2.9/src/ssl-params/main.c
5fb73d
--- dovecot-2.2.9/src/ssl-params/main.c.fixit	2013-11-24 14:37:39.000000000 +0100
5fb73d
+++ dovecot-2.2.9/src/ssl-params/main.c	2013-11-27 17:51:06.664694558 +0100
5fb73d
@@ -103,7 +103,10 @@ static void sig_chld(const siginfo_t *si
5fb73d
 	if (waitpid(-1, &status, WNOHANG) < 0)
5fb73d
 		i_error("waitpid() failed: %m");
5fb73d
 	else if (status != 0)
5fb73d
+	{
5fb73d
 		i_error("child process failed with status %d", status);
5fb73d
+		if(master_service_get_flags(master_service) & MASTER_SERVICE_FLAG_STANDALONE) exit(1);
5fb73d
+	}
5fb73d
 	else {
5fb73d
 		/* params should have been created now. try refreshing. */
5fb73d
 		ssl_params_refresh(param);