r3673 - in branches/2.0/varnish-cache: bin/varnishd lib/libvcl
tfheen at projects.linpro.no
tfheen at projects.linpro.no
Fri Feb 6 14:51:11 CET 2009
Author: tfheen
Date: 2009-02-06 14:51:11 +0100 (Fri, 06 Feb 2009)
New Revision: 3673
Modified:
branches/2.0/varnish-cache/bin/varnishd/cache_vcl.c
branches/2.0/varnish-cache/lib/libvcl/vcc_compile.c
Log:
Merge r3480: Make VCC_Return_Name() return lower case, and use it also for the SMH logging.
Modified: branches/2.0/varnish-cache/bin/varnishd/cache_vcl.c
===================================================================
--- branches/2.0/varnish-cache/bin/varnishd/cache_vcl.c 2009-02-06 13:47:53 UTC (rev 3672)
+++ branches/2.0/varnish-cache/bin/varnishd/cache_vcl.c 2009-02-06 13:51:11 UTC (rev 3673)
@@ -46,6 +46,7 @@
#include "shmlog.h"
#include "vcl.h"
#include "cache.h"
+#include "libvcl.h"
struct vcls {
unsigned magic;
@@ -299,21 +300,6 @@
/*--------------------------------------------------------------------*/
-static const char *
-vcl_handlingname(unsigned u)
-{
-
- switch (u) {
-#define VCL_RET_MAC(a, b, c,d) case VCL_RET_##b: return(#a);
-#define VCL_RET_MAC_E(a, b, c,d) case VCL_RET_##b: return(#a);
-#include "vcl_returns.h"
-#undef VCL_RET_MAC
-#undef VCL_RET_MAC_E
- default:
- return (NULL);
- }
-}
-
#define VCL_RET_MAC(l,u,b,n)
#define VCL_MET_MAC(func, upper, bitmap) \
@@ -325,7 +311,7 @@
sp->cur_method = VCL_MET_ ## upper; \
WSP(sp, SLT_VCL_call, "%s", #func); \
sp->vcl->func##_func(sp); \
- WSP(sp, SLT_VCL_return, "%s", vcl_handlingname(sp->handling)); \
+ WSP(sp, SLT_VCL_return, "%s", VCC_Return_Name(sp->handling)); \
sp->cur_method = 0; \
assert(sp->handling & bitmap); \
assert(!(sp->handling & ~bitmap)); \
Modified: branches/2.0/varnish-cache/lib/libvcl/vcc_compile.c
===================================================================
--- branches/2.0/varnish-cache/lib/libvcl/vcc_compile.c 2009-02-06 13:47:53 UTC (rev 3672)
+++ branches/2.0/varnish-cache/lib/libvcl/vcc_compile.c 2009-02-06 13:51:11 UTC (rev 3673)
@@ -670,8 +670,8 @@
switch (method) {
case 0: return ("<none>");
-#define VCL_RET_MAC(l, u, b, i) case b: return(#u);
-#define VCL_RET_MAC_E(l, u, b, i) case b: return(#u);
+#define VCL_RET_MAC(l, u, b, i) case b: return(#l);
+#define VCL_RET_MAC_E(l, u, b, i) case b: return(#l);
#include "vcl_returns.h"
#undef VCL_RET_MAC_E
#undef VCL_RET_MAC
More information about the varnish-commit
mailing list