]> git.ipfire.org Git - thirdparty/strongswan.git/commitdiff
ha: Close control FIFO if it is not valid
authorTobias Brunner <tobias@strongswan.org>
Thu, 27 Aug 2015 12:31:42 +0000 (14:31 +0200)
committerTobias Brunner <tobias@strongswan.org>
Thu, 27 Aug 2015 12:31:42 +0000 (14:31 +0200)
src/libcharon/plugins/ha/ha_ctl.c

index 27ebb91c5e0602fd824cb26ebac257000813be59..54302e852281396abf0f2525c98a69f0c9a65b17 100644 (file)
@@ -111,6 +111,10 @@ static job_requeue_t dispatch_fifo(private_ha_ctl_t *this)
                        DBG1(DBG_CFG, "%s is not a FIFO, recreate it", HA_FIFO);
                        recreate_fifo();
                }
+               if (fifo != -1)
+               {
+                       close(fifo);
+               }
                sleep(1);
                return JOB_REQUEUE_FAIR;
        }