elf_compress would compress all (new) data chunks, but didn't reset
the section data_list. This would cause extra data to be returned
after decompression or create bad compressed data. Add a new testcase
for this and explicitly zap the scn->data_list before resetting the
elf section raw data after (de)compression.
* libelf/elf_compress.c (__libelf_reset_rawdata): Cleanup
scn->data_list.
* tests/newzdata.c: New testcase.
* tests/Makefile.am (check_PROGRAMS): Add newzdata.
(TESTS): Likewise.
(newzdata_LDADD): New variable.