From 6a41320d4061bd634551fd297ac2fad92f75615f Mon Sep 17 00:00:00 2001 From: des Date: Tue, 24 Jul 2007 11:39:55 +0000 Subject: [PATCH] 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 --- varnish-cache/bin/varnishd/cache_vrt.c | 8 ++++++++ 1 file changed, 8 insertions(+) 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) { -- 2.39.5