Commit dec9455a authored by Dag Haavi Finstad's avatar Dag Haavi Finstad

Fix for an issue where varnishlog reports an incorrect "Length" entry on gunzipped delivery

parent 0c82d957
......@@ -823,7 +823,7 @@ void VGZ_UpdateObj(const struct vgz*, struct object *);
int VGZ_WrwInit(struct vgz *vg);
int VGZ_WrwGunzip(struct worker *w, struct vgz *, const void *ibuf,
ssize_t ibufl);
void VGZ_WrwFlush(const struct worker *wrk, struct vgz *vg);
void VGZ_WrwFlush(struct worker *wrk, struct vgz *vg);
/* Return values */
#define VGZ_ERROR -1
......
......@@ -355,13 +355,15 @@ VGZ_WrwGunzip(struct worker *wrk, struct vgz *vg, const void *ibuf,
/*--------------------------------------------------------------------*/
void
VGZ_WrwFlush(const struct worker *wrk, struct vgz *vg)
VGZ_WrwFlush(struct worker *wrk, struct vgz *vg)
{
CHECK_OBJ_NOTNULL(wrk, WORKER_MAGIC);
CHECK_OBJ_NOTNULL(vg, VGZ_MAGIC);
if (vg->m_len == 0)
return;
wrk->acct_tmp.bodybytes += vg->m_len;
(void)WRW_Write(wrk, vg->m_buf, vg->m_len);
(void)WRW_Flush(wrk);
vg->m_len = 0;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment