From: des Date: Tue, 24 Jul 2007 11:39:55 +0000 (+0000) Subject: Implement VRT_r_obj_status(), without which obj.status can't be read. X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6a41320d4061bd634551fd297ac2fad92f75615f;p=varnish Implement VRT_r_obj_status(), without which obj.status can't be read. git-svn-id: svn+ssh://projects.linpro.no/svn/varnish/trunk@1745 d4fa192b-c00b-0410-8231-f00ffab90ce4 --- diff --git a/varnish-cache/bin/varnishd/cache_vrt.c b/varnish-cache/bin/varnishd/cache_vrt.c index dbc6314b..2518a4c4 100644 --- a/varnish-cache/bin/varnishd/cache_vrt.c +++ b/varnish-cache/bin/varnishd/cache_vrt.c @@ -234,6 +234,14 @@ VRT_l_obj_status(struct sess *sp, int num) http_SetH(&sp->obj->http, HTTP_HDR_STATUS, p); } +int +VRT_r_obj_status(struct sess *sp) +{ + CHECK_OBJ_NOTNULL(sp, SESS_MAGIC); + CHECK_OBJ_NOTNULL(sp->obj, OBJECT_MAGIC); + return (atoi(sp->obj->http.hd[HTTP_HDR_STATUS].b)); +} + void VRT_l_resp_status(struct sess *sp, int num) {