libarchive: fix xmalloc_open_zipped_read_close()

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
This commit is contained in:
Denys Vlasenko 2016-06-21 02:04:16 +02:00
parent 7cf45ae10e
commit 10c0e91786

View File

@ -331,6 +331,9 @@ void* FAST_FUNC xmalloc_open_zipped_read_close(const char *fname, size_t *maxsz_
} }
} else { } else {
/* File is not compressed */ /* File is not compressed */
//FIXME: avoid seek
xlseek(xstate->src_fd, - xstate->signature_skipped, SEEK_CUR);
xstate->signature_skipped = 0;
image = xmalloc_read(xstate->src_fd, maxsz_p); image = xmalloc_read(xstate->src_fd, maxsz_p);
} }