[master] 2c8505b VGZ_OK is acceptable at end of gzip objects.

Poul-Henning Kamp phk at varnish-cache.org
Tue Apr 12 13:57:23 CEST 2011


commit 2c8505ba39f2e7997efd6f5eb28cfb3cbb5c3822
Author: Poul-Henning Kamp <phk at FreeBSD.org>
Date:   Tue Apr 12 11:56:34 2011 +0000

    VGZ_OK is acceptable at end of gzip objects.
    
    Fixes	#891

diff --git a/bin/varnishd/cache_gzip.c b/bin/varnishd/cache_gzip.c
index a07eeeb..6a817c2 100644
--- a/bin/varnishd/cache_gzip.c
+++ b/bin/varnishd/cache_gzip.c
@@ -640,9 +640,9 @@ vfp_testgzip_bytes(struct sess *sp, struct http_conn *htc, ssize_t bytes)
 			}
 		}
 	}
-	if (i == Z_STREAM_END)
+	if (i == VGZ_OK || i == VGZ_END)
 		return (1);
-	WSP(sp, SLT_FetchError, "Incomplete Gzip data (not STREAM_END)");
+	WSP(sp, SLT_FetchError, "Gunzip trouble (%d)", i);
 	return (-1);
 }
 



More information about the varnish-commit mailing list