]> git.michaelhowe.org Git - packages/o/openafs.git/commitdiff
STABLE12-flushhostcps-20030407
authorDerrick Brashear <shadow@dementia.org>
Mon, 7 Apr 2003 18:39:25 +0000 (18:39 +0000)
committerDerrick Brashear <shadow@dementia.org>
Mon, 7 Apr 2003 18:39:25 +0000 (18:39 +0000)
make it so flushhostcps can't try to Release when no host was found,
which was apparently the problem dlc@cs really observed.

(cherry picked from commit dd517125c21e010954989d60caa31bc2da7ca394)

src/viced/host.c

index 6f29850820abe750f439d9f2f26e1e7eda2d538c..cabf71b64b8bfc2f2c266bd3d57e93f17ce22da0 100644 (file)
@@ -539,10 +539,10 @@ void h_flushhostcps(hostaddr, hport)
     H_LOCK
     host = h_Lookup_r(hostaddr, hport, &held);
     if (host) {
-      host->hcpsfailed = 1;
+       host->hcpsfailed = 1;
+       if (!held)
+           h_Release_r(host);
     }
-    if (!held)
-      h_Release_r(host);
     H_UNLOCK
 
 return;