From e87f2b683446fe424dc5e8fed60456240e080562 Mon Sep 17 00:00:00 2001 From: Dimitri Staessens Date: Sun, 3 Mar 2019 19:08:48 +0100 Subject: ipcpd: Refactor create_r and flow_req_arr The API calls for the IPCP to inform the IRMd of IPCP creation and incoming flow request had the pid_t in the call. This pid_t is removed and the getpid() call is now placed inside the function. Also refactors the cleanup for the main() functions of some of the lower IPCPs. Signed-off-by: Dimitri Staessens Signed-off-by: Sander Vrijders --- src/ipcpd/broadcast/main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/ipcpd/broadcast') diff --git a/src/ipcpd/broadcast/main.c b/src/ipcpd/broadcast/main.c index c1e5d4ab..71d1ddaa 100644 --- a/src/ipcpd/broadcast/main.c +++ b/src/ipcpd/broadcast/main.c @@ -304,7 +304,7 @@ int main(int argc, goto fail_boot; } - if (ipcp_create_r(getpid(), 0)) { + if (ipcp_create_r(0)) { log_err("Failed to notify IRMd we are initialized."); ipcp_set_state(IPCP_NULL); goto fail_create_r; @@ -342,6 +342,6 @@ int main(int argc, fail_rib_init: ipcp_fini(); fail_init: - ipcp_create_r(getpid(), -1); + ipcp_create_r(-1); exit(EXIT_FAILURE); } -- cgit v1.2.3