summaryrefslogtreecommitdiffstats
path: root/eigrpd
diff options
context:
space:
mode:
authorRenato Westphal <renato@opensourcerouting.org>2017-09-12 04:05:16 +0200
committerRenato Westphal <renato@opensourcerouting.org>2017-09-12 16:25:16 +0200
commit8879bd22672c9d2987dd5d4645a603ca060c0c3f (patch)
tree2af510f49651624a6055c3110bf8be946617a27a /eigrpd
parentMerge pull request #1154 from donaldsharp/bgp_aspath (diff)
downloadfrr-8879bd22672c9d2987dd5d4645a603ca060c0c3f.tar.xz
frr-8879bd22672c9d2987dd5d4645a603ca060c0c3f.zip
*: make all daemons call frr_fini() on exit
This allow us to find real leaks more easily with tools like valgrind. Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
Diffstat (limited to 'eigrpd')
-rw-r--r--eigrpd/eigrpd.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/eigrpd/eigrpd.c b/eigrpd/eigrpd.c
index 99d88b2d0..ee60898f8 100644
--- a/eigrpd/eigrpd.c
+++ b/eigrpd/eigrpd.c
@@ -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)