diff options
Diffstat (limited to 'libarchive/archive_write_set_format_7zip.c')
-rw-r--r-- | libarchive/archive_write_set_format_7zip.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/libarchive/archive_write_set_format_7zip.c b/libarchive/archive_write_set_format_7zip.c index 7847cb3..fc6ccfe 100644 --- a/libarchive/archive_write_set_format_7zip.c +++ b/libarchive/archive_write_set_format_7zip.c @@ -1450,6 +1450,10 @@ _7z_free(struct archive_write *a) { struct _7zip *zip = (struct _7zip *)a->format_data; + /* Close the temporary file. */ + if (zip->temp_fd >= 0) + close(zip->temp_fd); + file_free_register(zip); compression_end(&(a->archive), &(zip->stream)); free(zip->coder.props); |