diff options
author | ngie <ngie@FreeBSD.org> | 2017-05-22 06:04:20 +0000 |
---|---|---|
committer | ngie <ngie@FreeBSD.org> | 2017-05-22 06:04:20 +0000 |
commit | 0799e481e008ebfb8fd6ae1715e8f1e044468be6 (patch) | |
tree | d5086f44792f9288cf531fc130d10f31a1b805f6 /usr.sbin | |
parent | 9fc6a0e2816c004ecbd81e9c88aff3ecd0b75bb5 (diff) | |
download | FreeBSD-src-0799e481e008ebfb8fd6ae1715e8f1e044468be6.zip FreeBSD-src-0799e481e008ebfb8fd6ae1715e8f1e044468be6.tar.gz |
MFC r317154:
Print out the signal number on exit in terminate(..) if WARMSTART is compiled
into rpcbind.
The signal number can provide helpful diagnostic info.
Obtained from: Isilon OneFS
Diffstat (limited to 'usr.sbin')
-rw-r--r-- | usr.sbin/rpcbind/rpcbind.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/usr.sbin/rpcbind/rpcbind.c b/usr.sbin/rpcbind/rpcbind.c index a2b5e60..e1e3799 100644 --- a/usr.sbin/rpcbind/rpcbind.c +++ b/usr.sbin/rpcbind/rpcbind.c @@ -755,12 +755,13 @@ rbllist_add(rpcprog_t prog, rpcvers_t vers, struct netconfig *nconf, * Catch the signal and die */ static void -terminate(int dummy __unused) +terminate(int signum __unused) { close(rpcbindlockfd); #ifdef WARMSTART syslog(LOG_ERR, - "rpcbind terminating on signal. Restart with \"rpcbind -w\""); + "rpcbind terminating on signal %d. Restart with \"rpcbind -w\"", + signum); write_warmstart(); /* Dump yourself */ #endif exit(2); |