]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
master: Don't throttle services that are already being destroyed
authorTimo Sirainen <timo.sirainen@dovecot.fi>
Thu, 21 Sep 2017 14:53:04 +0000 (17:53 +0300)
committerTimo Sirainen <timo.sirainen@dovecot.fi>
Thu, 21 Sep 2017 14:53:04 +0000 (17:53 +0300)
If process couldn't be created, because the service_list is already being
destroyed (e.g. due to reload), also don't enable unnecessary throttling
for the service.

Hopefully fixes these random errors that are logged alone:
master: Error: service(...): command startup failed, throttling for 2 secs

src/master/service-monitor.c

index c13d6bf84ac7a2ca9f30b921bdf9b31f0662a983..16fa13cf29460202050c928e4d3404e31cbfa8a4 100644 (file)
@@ -192,7 +192,7 @@ static void service_status_input(struct service *service)
 
 static void service_monitor_throttle(struct service *service)
 {
-       if (service->to_throttle != NULL)
+       if (service->to_throttle != NULL || service->list->destroying)
                return;
 
        i_assert(service->throttle_secs > 0);