From d6e1a033b0d36973e59011f93926e9b6462650fd Mon Sep 17 00:00:00 2001 From: Derrick Brashear Date: Mon, 7 Apr 2003 18:39:25 +0000 Subject: [PATCH] STABLE12-flushhostcps-20030407 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 | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/viced/host.c b/src/viced/host.c index 6f2985082..cabf71b64 100644 --- a/src/viced/host.c +++ b/src/viced/host.c @@ -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; -- 2.39.5