platform_system_core/libziparchive/testdata
Elliott Hughes fba2a1a1ec Fix SEGV in libziparchive with malformed zip file.
d77c99ebc3 changed MappedFile to return a
bogus zero-length mapping on failure rather than nullptr. None of the
calling code was changed, though, and it seems like doing so would be a
bad idea. Revert that part of the change.

Add missing tests, and tidy up some of the logging. Also remove
single-use or obfuscatory constants from the tests.

The new "empty.zip" was created by using zip(1) to create a zip file
with one entry, then using `zip -d` to remove it.

The new "zero-size-cd.zip" was created by using zip(1) to create a zip
file containing a single empty file, and then hex editing the two byte
"size of the central directory" field in the "end of central directory
record" structure at the end of the file. (This is equivalent to, but
much smaller than, the example zip file provided by the bug reporter.)

Bug: http://b/145925341
Test: treehugger
Change-Id: Iff64673bce7dae886ccbc9dd6c2bbe18de19f9d2
2019-12-17 08:39:09 -08:00
..
bad_crc.zip
bad_filename.zip
crash.apk
declaredlength.zip
dummy-update.zip
empty.zip Fix SEGV in libziparchive with malformed zip file. 2019-12-17 08:39:09 -08:00
large.zip
valid.zip
zero-size-cd.zip Fix SEGV in libziparchive with malformed zip file. 2019-12-17 08:39:09 -08:00