]> err.no Git - varnish/commitdiff
move object twiddling from FetchHdr() to cache_center.c
authorphk <phk@d4fa192b-c00b-0410-8231-f00ffab90ce4>
Fri, 27 Feb 2009 12:10:01 +0000 (12:10 +0000)
committerphk <phk@d4fa192b-c00b-0410-8231-f00ffab90ce4>
Fri, 27 Feb 2009 12:10:01 +0000 (12:10 +0000)
git-svn-id: svn+ssh://projects.linpro.no/svn/varnish/trunk@3835 d4fa192b-c00b-0410-8231-f00ffab90ce4

varnish-cache/bin/varnishd/cache_center.c
varnish-cache/bin/varnishd/cache_fetch.c

index a58521e11992922c1ddb1d83379bf301409d6a57..e04847500a6667fc73bc5f9d613c46e114a07aa3 100644 (file)
@@ -385,7 +385,11 @@ cnt_fetch(struct sess *sp)
        AN(sp->bereq);
        AN(sp->director);
        AZ(sp->vbe);
+
+       sp->obj->xid = sp->xid;
+       WS_Assert(sp->obj->ws_o);
        i = FetchHdr(sp);
+       
        if (i == 0)
                i = FetchBody(sp);
        AZ(sp->wrk->wfd);
index 109d0ac5b18503a714d1a86bbbd720efdcfd1213..3c8820aedc1852dd15da9b515c4dbf60a2297a2d 100644 (file)
@@ -333,10 +333,6 @@ FetchHdr(struct sess *sp)
        bereq = sp->bereq;
        hp = &bereq->http[0];
 
-       sp->obj->xid = sp->xid;
-
-       /* Set up obj's workspace */
-       WS_Assert(sp->obj->ws_o);
        VBE_GetFd(sp);
        if (sp->vbe == NULL)
                return (__LINE__);
@@ -393,9 +389,7 @@ FetchHdr(struct sess *sp)
                /* XXX: other cleanup ? */
                return (__LINE__);
        }
-
        return (0);
-
 }
 
 /*--------------------------------------------------------------------*/