diff options
author | Adam <Adam@anope.org> | 2011-10-15 02:08:52 -0400 |
---|---|---|
committer | Adam <Adam@anope.org> | 2011-10-15 02:08:52 -0400 |
commit | 2c614d5aabc787c0054bdcc813001dabb3e4b0d4 (patch) | |
tree | df18f9c534aa93c5ae7c3ae3533249e6cec2246e /src/init.cpp | |
parent | 89b4be681de8c9242abbe05c499a1426290d947c (diff) |
Fixed up anoperc to work with the newer startup method
Diffstat (limited to 'src/init.cpp')
-rw-r--r-- | src/init.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/init.cpp b/src/init.cpp index cd2430f8b..e1ccf6c17 100644 --- a/src/init.cpp +++ b/src/init.cpp @@ -267,9 +267,11 @@ class SignalSigChld : public Signal void OnNotify() { - int status = 0; + int status = 0, ret = -1; wait(&status); - exit(status); + if (WIFEXITED(status)) + ret = WEXITSTATUS(status); + exit(ret); } }; #endif |