aboutsummaryrefslogtreecommitdiff
path: root/sbin
diff options
context:
space:
mode:
authorPawel Jakub Dawidek <pjd@FreeBSD.org>2010-04-28 22:26:30 +0000
committerPawel Jakub Dawidek <pjd@FreeBSD.org>2010-04-28 22:26:30 +0000
commit06c117d1d131b959374ba1655d3cc4f78ebc8bac (patch)
tree079d732ae33f3eb9c10653d3b61f5e9f30c2c6af /sbin
parent3f5e024c14555baa738f26c1db574097666fe4b8 (diff)
downloadsrc-06c117d1d131b959374ba1655d3cc4f78ebc8bac.tar.gz
src-06c117d1d131b959374ba1655d3cc4f78ebc8bac.zip
Use WEXITSTATUS() to obtain real exit code.
MFC after: 3 days
Notes
Notes: svn path=/head/; revision=207345
Diffstat (limited to 'sbin')
-rw-r--r--sbin/hastd/hastd.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/sbin/hastd/hastd.c b/sbin/hastd/hastd.c
index 957885d7ac14..50bc9ffad819 100644
--- a/sbin/hastd/hastd.c
+++ b/sbin/hastd/hastd.c
@@ -294,9 +294,10 @@ listen_accept(void)
"Waiting for worker process (pid=%u) failed",
(unsigned int)res->hr_workerpid);
/* See above. */
- } else if (status != 0) {
+ } else if (WEXITSTATUS(status) != 0) {
pjdlog_error("Worker process (pid=%u) exited ungracefully: status=%d.",
- (unsigned int)res->hr_workerpid, status);
+ (unsigned int)res->hr_workerpid,
+ WEXITSTATUS(status));
/* See above. */
} else {
pjdlog_debug(1,