mirror of
https://github.com/troglobit/finit.git
synced 2026-10-02 05:52:48 +07:00
service_enabled(): Only check WCOREDUMP() from if WIFSIGNALED()
Patch courtesy of Westermo. Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
This commit is contained in:
@@ -128,7 +128,7 @@ svc_cmd_t service_enabled(svc_t *svc, int event, void *arg)
|
||||
return WEXITSTATUS(status);
|
||||
|
||||
/* Check for SEGFAULT or other error ... */
|
||||
if (WCOREDUMP(status))
|
||||
if (WIFSIGNALED(status) && WCOREDUMP(status))
|
||||
_e("Callback to %s crashed!\n", svc->cmd);
|
||||
else
|
||||
_e("Callback to %s did not exit normally!\n", svc->cmd);
|
||||
|
||||
Reference in New Issue
Block a user