[master] ace9bce Don't rely on busyobj for cheap optimization
Poul-Henning Kamp
phk at FreeBSD.org
Tue Jul 15 11:30:24 CEST 2014
commit ace9bce68363f3fc2759e37268ded2b30c71ae34
Author: Poul-Henning Kamp <phk at FreeBSD.org>
Date: Tue Jul 15 09:24:47 2014 +0000
Don't rely on busyobj for cheap optimization
diff --git a/bin/varnishd/cache/cache_gzip.c b/bin/varnishd/cache/cache_gzip.c
index 5abefbb..904d26d 100644
--- a/bin/varnishd/cache/cache_gzip.c
+++ b/bin/varnishd/cache/cache_gzip.c
@@ -456,10 +456,9 @@ vfp_gzip_init(struct vfp_ctx *vc, struct vfp_entry *vfe)
struct vgz *vg;
CHECK_OBJ_NOTNULL(vc, VFP_CTX_MAGIC);
- CHECK_OBJ_NOTNULL(vc->bo, BUSYOBJ_MAGIC);
CHECK_OBJ_NOTNULL(vfe, VFP_ENTRY_MAGIC);
- if (vc->bo->content_length == 0) {
+ if (http_HdrIs(vc->http, H_Content_Length, "0")) {
http_Unset(vc->http, H_Content_Encoding);
return (VFP_NULL);
}
More information about the varnish-commit
mailing list