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

src/viced/host.c

index 890491044cd3a66f84c2af6f649b4a9257dc24d7..fdcb6dc35c982cf39805fc6f260b1a02cc97bd76 100644 (file)
@@ -504,10 +504,10 @@ void h_flushhostcps(register afs_uint32 hostaddr, register afs_uint32 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;