summaryrefslogtreecommitdiff
path: root/src/rc/runscript.c
diff options
context:
space:
mode:
authorRoy Marples <roy@marples.name>2009-05-05 10:24:21 +0100
committerRoy Marples <roy@marples.name>2009-05-05 10:24:21 +0100
commit43063ae7c2faab221c877defc1957364321a8fa2 (patch)
tree6735e254348ba13a7f7415fe6e0746808d3b7e13 /src/rc/runscript.c
parente575b33047d501d96bb42679dcd709b9c3bee265 (diff)
downloadopenrc-43063ae7c2faab221c877defc1957364321a8fa2.tar.gz
openrc-43063ae7c2faab221c877defc1957364321a8fa2.tar.bz2
openrc-43063ae7c2faab221c877defc1957364321a8fa2.tar.xz
Fix compile on NetBSD and FreeBSD
Diffstat (limited to 'src/rc/runscript.c')
-rw-r--r--src/rc/runscript.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/rc/runscript.c b/src/rc/runscript.c
index 8e6b782..cec7e01 100644
--- a/src/rc/runscript.c
+++ b/src/rc/runscript.c
@@ -450,7 +450,8 @@ svc_exec(const char *arg1, const char *arg2)
master_tty = -1;
}
- ret = WEXITSTATUS(rc_waitpid(service_pid));
+ ret = rc_waitpid(service_pid);
+ ret = WEXITSTATUS(ret);
if (ret != 0 && errno == ECHILD)
/* killall5 -9 could cause this */
ret = 0;