summaryrefslogtreecommitdiffstats
path: root/sbin/hastd
diff options
context:
space:
mode:
authorpjd <pjd@FreeBSD.org>2010-04-28 22:26:30 +0000
committerpjd <pjd@FreeBSD.org>2010-04-28 22:26:30 +0000
commit166a203d5e0b13f7fa327cfc93e8869e75e6399b (patch)
tree079d732ae33f3eb9c10653d3b61f5e9f30c2c6af /sbin/hastd
parent4c851553838a2dd95a2de9b439d36e29fb5db240 (diff)
downloadFreeBSD-src-166a203d5e0b13f7fa327cfc93e8869e75e6399b.zip
FreeBSD-src-166a203d5e0b13f7fa327cfc93e8869e75e6399b.tar.gz
Use WEXITSTATUS() to obtain real exit code.
MFC after: 3 days
Diffstat (limited to 'sbin/hastd')
-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 957885d..50bc9ff 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,
OpenPOWER on IntegriCloud