mirror of
https://github.com/rsmarples/dhcpcd.git
synced 2024-11-23 18:14:09 +08:00
Improve logging of script exiting.
This commit is contained in:
parent
9530feed8a
commit
31389eea99
2
configure
vendored
2
configure
vendored
@ -240,7 +240,7 @@ fi
|
||||
|
||||
case "$OS" in
|
||||
linux)
|
||||
echo "CPPFLAGS+= -D_BSD_SOURCE -D_XOPEN_SOURCE=600" >>$CONFIG_MK
|
||||
echo "CPPFLAGS+= -D_BSD_SOURCE -D_XOPEN_SOURCE=700" >>$CONFIG_MK
|
||||
echo "SRCS+= if-linux.c if-linux-wireless.c lpf.c" >>$CONFIG_MK
|
||||
echo "SRCS+= platform-linux.c" >>$CONFIG_MK
|
||||
echo "LDADD+= -lrt" >>$CONFIG_MK
|
||||
|
11
configure.c
11
configure.c
@ -435,9 +435,14 @@ run_script_reason(const struct interface *iface, const char *reason)
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (WEXITSTATUS(status) == 127)
|
||||
syslog(LOG_ERR, "exec_script: %s: WEXITSTATUS %d",
|
||||
argv[0], WEXITSTATUS(status));
|
||||
if (WIFEXITED(status)) {
|
||||
if (WEXITSTATUS(status))
|
||||
syslog(LOG_ERR,
|
||||
"exec_script: %s: WEXITSTATUS %d",
|
||||
argv[0], WEXITSTATUS(status));
|
||||
} else if (WIFSIGNALED(status))
|
||||
syslog(LOG_ERR, "exec_sript: %s: %s",
|
||||
argv[0], strsignal(WTERMSIG(status)));
|
||||
}
|
||||
|
||||
/* Send to our listeners */
|
||||
|
Loading…
Reference in New Issue
Block a user