mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-05 22:07:57 +00:00
Merge pull request #1162 from opensourcerouting/clean_exit
*: make all daemons call frr_fini() on exit
This commit is contained in:
commit
c56fdaa5db
@ -335,6 +335,7 @@ babel_exit_properly(void)
|
||||
babel_save_state_file();
|
||||
debugf(BABEL_DEBUG_COMMON, "Remove pid file.");
|
||||
debugf(BABEL_DEBUG_COMMON, "Done.");
|
||||
frr_fini();
|
||||
|
||||
exit(0);
|
||||
}
|
||||
|
@ -42,6 +42,7 @@
|
||||
#include "plist.h"
|
||||
#include "sockopt.h"
|
||||
#include "keychain.h"
|
||||
#include "libfrr.h"
|
||||
|
||||
#include "eigrpd/eigrp_structs.h"
|
||||
#include "eigrpd/eigrpd.h"
|
||||
@ -241,12 +242,10 @@ void eigrp_terminate(void)
|
||||
|
||||
SET_FLAG(eigrp_om->options, EIGRP_MASTER_SHUTDOWN);
|
||||
|
||||
/* exit immediately if EIGRP not actually running */
|
||||
if (listcount(eigrp_om->eigrp) == 0)
|
||||
exit(0);
|
||||
|
||||
for (ALL_LIST_ELEMENTS(eigrp_om->eigrp, node, nnode, eigrp))
|
||||
eigrp_finish(eigrp);
|
||||
|
||||
frr_fini();
|
||||
}
|
||||
|
||||
void eigrp_finish(struct eigrp *eigrp)
|
||||
|
@ -35,6 +35,7 @@
|
||||
#include "linklist.h"
|
||||
#include "nexthop.h"
|
||||
#include "vrf.h"
|
||||
#include "libfrr.h"
|
||||
|
||||
#include "isisd/dict.h"
|
||||
#include "isisd/isis_constants.h"
|
||||
@ -427,4 +428,5 @@ void isis_zebra_stop(void)
|
||||
{
|
||||
zclient_stop(zclient);
|
||||
zclient_free(zclient);
|
||||
frr_fini();
|
||||
}
|
||||
|
@ -35,6 +35,7 @@
|
||||
#include "plist.h"
|
||||
#include "sockopt.h"
|
||||
#include "bfd.h"
|
||||
#include "libfrr.h"
|
||||
#include "defaults.h"
|
||||
|
||||
#include "ospfd/ospfd.h"
|
||||
@ -489,6 +490,8 @@ void ospf_terminate(void)
|
||||
*/
|
||||
zclient_stop(zclient);
|
||||
zclient_free(zclient);
|
||||
|
||||
frr_fini();
|
||||
}
|
||||
|
||||
void ospf_finish(struct ospf *ospf)
|
||||
|
@ -139,4 +139,6 @@ void pim_terminate()
|
||||
zclient_stop(zclient);
|
||||
zclient_free(zclient);
|
||||
}
|
||||
|
||||
frr_fini();
|
||||
}
|
||||
|
@ -89,6 +89,7 @@ static void sigint(void)
|
||||
rip_clean();
|
||||
|
||||
rip_zclient_stop();
|
||||
frr_fini();
|
||||
|
||||
exit(0);
|
||||
}
|
||||
|
@ -92,6 +92,7 @@ static void sigint(void)
|
||||
ripng_clean();
|
||||
|
||||
ripng_zebra_stop();
|
||||
frr_fini();
|
||||
exit(0);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user