]> err.no Git - varnish/commitdiff
Always release WRW, also on error.
authorphk <phk@d4fa192b-c00b-0410-8231-f00ffab90ce4>
Wed, 26 Nov 2008 16:10:19 +0000 (16:10 +0000)
committerphk <phk@d4fa192b-c00b-0410-8231-f00ffab90ce4>
Wed, 26 Nov 2008 16:10:19 +0000 (16:10 +0000)
git-svn-id: svn+ssh://projects.linpro.no/svn/varnish/trunk@3446 d4fa192b-c00b-0410-8231-f00ffab90ce4

varnish-cache/bin/varnishd/cache_fetch.c

index 2446e59b71893d82d2e930753395039153361c23..83fbbda358a96f86827b2eef4d950c341d6e7cc8 100644 (file)
@@ -353,12 +353,7 @@ Fetch(struct sess *sp)
 
        /* Deal with any message-body the request might have */
        i = FetchReqBody(sp);
-       if (i > 0) {
-               VBE_ClosedFd(sp);
-               return (__LINE__);
-       }
-
-       if (WRW_FlushRelease(w)) {
+       if (WRW_FlushRelease(w) || i > 0) {
                VBE_ClosedFd(sp);
                /* XXX: other cleanup ? */
                return (__LINE__);