diagnose unexpected EOF and zero lengths in packed data
authorPaul Eggert <eggert@cs.ucla.edu>
Sat, 8 Dec 2012 18:45:18 +0000 (10:45 -0800)
committerPaul Eggert <eggert@cs.ucla.edu>
Mon, 10 Dec 2012 17:43:21 +0000 (09:43 -0800)
commitf2be148c3d956c2dd19bd6fdbe6de977e86cba35
treee63b4d60a0ea9e6bc0098421d70d4caf6c2234fb
parent16977ae732bf60f79c9a4fd6d183662530ae7784
diagnose unexpected EOF and zero lengths in packed data

Problem reported by Aki Helin.
* NEWS: Mention Aki's reports.
* tests/unpack-invalid: New file,
with test data suggested by Aki.
* tests/Makefile.am (TESTS): Add it.
* unpack.c (read_byte): New function.
(look_bits, read_tree): Use it.
(read_tree): Check against zero bit length Huffman code.
NEWS
tests/Makefile.am
tests/unpack-invalid [new file with mode: 0755]
unpack.c