The deflate_stored() function needed to support Z_INSERT_ONLY.
authorWayne Davison <wayned@samba.org>
Sun, 2 Jan 2005 08:49:47 +0000 (08:49 +0000)
committerWayne Davison <wayned@samba.org>
Sun, 2 Jan 2005 08:49:47 +0000 (08:49 +0000)
zlib/deflate.c

index 74f67cf..20209df 100644 (file)
@@ -1092,6 +1092,11 @@ local block_state deflate_stored(s, flush)
         max_block_size = s->pending_buf_size - 5;
     }
 
+    if (flush == Z_INSERT_ONLY) {
+       s->block_start = s->strstart;
+       return need_more;
+    }
+
     /* Copy as much as possible from input to output: */
     for (;;) {
         /* Fill the window as much as possible: */