From 086cdb8b95c7e336335f31fcdba1f7283805a2c3 Mon Sep 17 00:00:00 2001 From: Nishant Chaprana Date: Tue, 27 Jun 2017 14:19:33 +0530 Subject: [PATCH] Ignoring SIGCHLD signal as exit status if child process is not required. Description: This patch ignores the SIGCHLD event, so that kernel can reap the child process automatically so that process table is properly updated. Change-Id: I09283dbee630359a5daa5c2d25f97a65ac6dda3e Signed-off-by: Nishant Chaprana --- packaging/stc-manager.spec | 2 +- src/stc-manager.c | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/packaging/stc-manager.spec b/packaging/stc-manager.spec index f9ff828..d9ab976 100644 --- a/packaging/stc-manager.spec +++ b/packaging/stc-manager.spec @@ -1,6 +1,6 @@ Name: stc-manager Summary: STC(Smart Traffic Control) manager -Version: 0.0.17 +Version: 0.0.18 Release: 0 Group: Network & Connectivity/Other License: Apache-2.0 diff --git a/src/stc-manager.c b/src/stc-manager.c index 6af6b7b..a732b72 100755 --- a/src/stc-manager.c +++ b/src/stc-manager.c @@ -14,6 +14,7 @@ * limitations under the License. */ +#include #include "stc-manager.h" #include "stc-emulator.h" #include "stc-statistics.h" @@ -89,6 +90,8 @@ gint32 main(gint32 argc, gchar *argv[]) GMainLoop *main_loop = NULL; gint32 ret = -1; + signal(SIGCHLD, SIG_IGN); + STC_LOGI("Smart Traffic Control Manager"); if (daemon(0, 0) != 0) -- 2.7.4