Commit 068412de authored by Poul-Henning Kamp's avatar Poul-Henning Kamp

Add a VGZ_ObufFull() function

parent 9e69e5bd
......@@ -643,6 +643,7 @@ struct vgz *VGZ_NewGzip(struct sess *sp);
void VGZ_Ibuf(struct vgz *, const void *, ssize_t len);
int VGZ_IbufEmpty(const struct vgz *vg);
void VGZ_Obuf(struct vgz *, const void *, ssize_t len);
int VGZ_ObufFull(const struct vgz *vg);
int VGZ_ObufStorage(const struct sess *sp, struct vgz *vg);
int VGZ_Gzip(struct vgz *, const void **, size_t *len, enum vgz_flag);
int VGZ_Gunzip(struct vgz *, const void **, size_t *len);
......
......@@ -235,6 +235,14 @@ VGZ_Obuf(struct vgz *vg, const void *ptr, ssize_t len)
vg->vz.avail_out = len;
}
int
VGZ_ObufFull(const struct vgz *vg)
{
CHECK_OBJ_NOTNULL(vg, VGZ_MAGIC);
return (vg->vz.avail_out == 0);
}
/*--------------------------------------------------------------------
* Keep the outbuffer supplied with storage and file it under the
* sp->obj as it fills.
......
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