From c94df2a2703c10a1b9edc60fe837c0330b8849d4 Mon Sep 17 00:00:00 2001 From: Tim Kientzle Date: Sun, 11 Apr 2010 17:18:09 -0400 Subject: [PATCH] If we're not creating the file because of the NEWER test, tell the writer not to bother sending us the file data. SVN-Revision: 2233 --- libarchive/archive_write_disk.c | 1 + 1 file changed, 1 insertion(+) diff --git a/libarchive/archive_write_disk.c b/libarchive/archive_write_disk.c index 8a99a2ba1..1890a7eb9 100644 --- a/libarchive/archive_write_disk.c +++ b/libarchive/archive_write_disk.c @@ -1087,6 +1087,7 @@ restore_entry(struct archive_write_disk *a) if ((a->flags & ARCHIVE_EXTRACT_NO_OVERWRITE_NEWER) && !S_ISDIR(a->st.st_mode)) { if (!older(&(a->st), a->entry)) { + archive_entry_unset_size(a->entry); archive_set_error(&a->archive, 0, "File on disk is not older; skipping."); return (ARCHIVE_FAILED); -- 2.47.3