summaryrefslogtreecommitdiff
path: root/src/ipcpd/normal
diff options
context:
space:
mode:
authorDimitri Staessens <dimitri.staessens@ugent.be>2018-04-26 12:40:10 +0200
committerSander Vrijders <sander.vrijders@ugent.be>2018-04-26 12:57:59 +0200
commitf98a17855f20018b6a4635e26bae8c820eb192d2 (patch)
treeb7290f59c2fec9f0f6b47bab09c713aa0e5f738c /src/ipcpd/normal
parenta4b16942119a09a7292b2f910569f48efc7d7049 (diff)
downloadouroboros-f98a17855f20018b6a4635e26bae8c820eb192d2.tar.gz
ouroboros-f98a17855f20018b6a4635e26bae8c820eb192d2.zip
ipcpd: Create notifier before connmgr
The connmgr requires the notifier, but the notifier was created after and destroyed before the connmgr. This is now fixed. Signed-off-by: Dimitri Staessens <dimitri.staessens@ugent.be> Signed-off-by: Sander Vrijders <sander.vrijders@ugent.be>
Diffstat (limited to 'src/ipcpd/normal')
-rw-r--r--src/ipcpd/normal/main.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/ipcpd/normal/main.c b/src/ipcpd/normal/main.c
index ba3fe33f..152f7640 100644
--- a/src/ipcpd/normal/main.c
+++ b/src/ipcpd/normal/main.c
@@ -309,6 +309,11 @@ int main(int argc,
goto fail_rib_init;
}
+ if (notifier_init()) {
+ log_err("Failed to initialize notifier component.");
+ goto fail_notifier_init;
+ }
+
if (connmgr_init()) {
log_err("Failed to initialize connection manager.");
goto fail_connmgr_init;
@@ -319,11 +324,6 @@ int main(int argc,
goto fail_enroll_init;
}
- if (notifier_init()) {
- log_err("Failed to initialize notifier component.");
- goto fail_notifier_init;
- }
-
if (ipcp_boot() < 0) {
log_err("Failed to boot IPCP.");
goto fail_boot;
@@ -343,12 +343,12 @@ int main(int argc,
finalize_components();
}
- notifier_fini();
-
enroll_fini();
connmgr_fini();
+ notifier_fini();
+
rib_fini();
ipcp_fini();
@@ -358,12 +358,12 @@ int main(int argc,
fail_create_r:
ipcp_shutdown();
fail_boot:
- notifier_fini();
- fail_notifier_init:
enroll_fini();
fail_enroll_init:
connmgr_fini();
fail_connmgr_init:
+ notifier_fini();
+ fail_notifier_init:
rib_fini();
fail_rib_init:
ipcp_fini();