diff options
Diffstat (limited to 'trees.c')
-rw-r--r-- | trees.c | 11 |
1 files changed, 11 insertions, 0 deletions
@@ -739,6 +739,17 @@ void ct_stored_block(s, buf, stored_len, eof) | |||
739 | } | 739 | } |
740 | 740 | ||
741 | /* =========================================================================== | 741 | /* =========================================================================== |
742 | * Send one empty static block to give enough lookahead for inflate | ||
743 | */ | ||
744 | void ct_align(s) | ||
745 | deflate_state *s; | ||
746 | { | ||
747 | send_bits(s, STATIC_TREES<<1, 3); | ||
748 | send_code(s, END_BLOCK, static_ltree); | ||
749 | s->compressed_len += 10L; /* 3 for block type, 7 for EOB */ | ||
750 | } | ||
751 | |||
752 | /* =========================================================================== | ||
742 | * Determine the best encoding for the current block: dynamic trees, static | 753 | * Determine the best encoding for the current block: dynamic trees, static |
743 | * trees or store, and output the encoded block to the zip file. This function | 754 | * trees or store, and output the encoded block to the zip file. This function |
744 | * returns the total compressed length for the file so far. | 755 | * returns the total compressed length for the file so far. |