/* Builds the canonical Huffman code for the main tree, the length tree, and the
* aligned offset tree. */
-static void
+static void
lzx_make_huffman_codes(const struct lzx_freq_tables *freq_tabs,
struct lzx_codes *codes)
{
/* The input data must be preprocessed. To avoid changing the original
* input, copy it to a temporary buffer. */
memcpy(uncompressed_data, __uncompressed_data, uncompressed_len);
+ memset(uncompressed_data + uncompressed_len, 0, 8);
/* Before doing any actual compression, do the call instruction (0xe8
* byte) translation on the uncompressed data. */