From: Ben Kaduk Date: Fri, 29 Oct 2010 02:45:33 +0000 (-0400) Subject: FBSD: fix dumb panic when we can't pfind rxk_Listener X-Git-Tag: openafs-devel-1_5_78~11 X-Git-Url: https://git.michaelhowe.org/gitweb/?a=commitdiff_plain;h=51363199a658c74fc9481cedbaf44bdddc4c8441;p=packages%2Fo%2Fopenafs.git FBSD: fix dumb panic when we can't pfind rxk_Listener The process is only returned locked if the process is found. Don't try to unlock it if it's not found. Reviewed-on: http://gerrit.openafs.org/3186 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear (cherry picked from commit 832607318b9ad4ab38bb62515cdb4959cc21a656) Change-Id: Ic4274a4a5640166669714798b909b2efb3b84cdb Reviewed-on: http://gerrit.openafs.org/3237 Tested-by: BuildBot --- diff --git a/src/rx/FBSD/rx_knet.c b/src/rx/FBSD/rx_knet.c index 187ee4c87..8072ba838 100644 --- a/src/rx/FBSD/rx_knet.c +++ b/src/rx/FBSD/rx_knet.c @@ -89,9 +89,10 @@ osi_StopListener(void) soshutdown(rx_socket, SHUT_RDWR); p = pfind(rxk_ListenerPid); afs_warn("osi_StopListener: rxk_ListenerPid %lx\n", p); - if (p) + if (p) { psignal(p, SIGUSR1); - PROC_UNLOCK(p); + PROC_UNLOCK(p); + } #ifdef AFS_FBSD70_ENV { /* Avoid destroying socket until osi_NetReceive has