[LEDE-DEV] [PATCH] remove pidfile when daemon dies and is not respawned

Jurgen Van Ham juvanham.tc at gmail.com
Mon Jul 4 23:13:28 PDT 2016


When a daemon dies unexpectedly and it will not be respawned, the
pidfile needs to be removed. (halt is set as !respawn)
--- a/service/instance.c        2016-07-01 14:22:53.507113056 +0200
+++ b/service/instance.c        2016-07-01 14:24:38.541075073 +0200
@@ -513,7 +513,7 @@

        uloop_timeout_cancel(&in->timeout);
        if (in->halt) {
-               /* no action */
+               instance_removepid(in);
        } else if (in->restart) {
                instance_start(in);
        } else if (in->respawn) {



More information about the Lede-dev mailing list