diff options
Diffstat (limited to 'archival/libarchive/decompress_uncompress.c')
-rw-r--r-- | archival/libarchive/decompress_uncompress.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/archival/libarchive/decompress_uncompress.c b/archival/libarchive/decompress_uncompress.c index 289f9e2..e9bbfb9 100644 --- a/archival/libarchive/decompress_uncompress.c +++ b/archival/libarchive/decompress_uncompress.c @@ -73,7 +73,7 @@ */ IF_DESKTOP(long long) int FAST_FUNC -unpack_Z_stream(int src_fd, int dst_fd) +unpack_Z_stream(transformer_aux_data_t *aux, int src_fd, int dst_fd) { IF_DESKTOP(long long total_written = 0;) IF_DESKTOP(long long) int retval = -1; @@ -103,6 +103,9 @@ unpack_Z_stream(int src_fd, int dst_fd) /* block compress mode -C compatible with 2.0 */ int block_mode; /* = BLOCK_MODE; */ + if (check_signature16(aux, src_fd, COMPRESS_MAGIC)) + return -1; + inbuf = xzalloc(IBUFSIZ + 64); outbuf = xzalloc(OBUFSIZ + 2048); htab = xzalloc(HSIZE); /* wasn't zeroed out before, maybe can xmalloc? */ |