From e563240b951016e25babe4b1720e206c926d07c2 Mon Sep 17 00:00:00 2001 From: Sergey Poznyakoff Date: Tue, 31 Aug 2004 11:45:55 +0000 Subject: [PATCH] (verify_volume): Call set_next_block_after if read_header returns HEADER_FAILURE Destroy and reinitialize content of current_stat_info and extended_header after each iteration. Issue a warning if the archive created contains some members whose file names were stripped off their leading prefixes. This is a temporary fix of the issue reported by Bdale Garbee (Refs: Debian bug 230064, Message-Id <87n07kyzhi.fsf@rover.gag.com>, Sun, 15 Feb 2004 11:22:17 -0700) --- src/compare.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/src/compare.c b/src/compare.c index ebcb8c2..b790a7a 100644 --- a/src/compare.c +++ b/src/compare.c @@ -494,6 +494,14 @@ diff_archive (void) void verify_volume (void) { + if (removed_prefixes_p ()) + { + WARN((0, 0, + _("Archive contains file names with leading prefixes removed."))); + WARN((0, 0, + _("Verification may fail to locate original files."))); + } + if (!diff_buffer) diff_init (); @@ -555,6 +563,7 @@ verify_volume (void) do { counter++; + set_next_block_after (current_header); status = read_header (false); } while (status == HEADER_FAILURE); @@ -568,6 +577,8 @@ verify_volume (void) break; diff_archive (); + tar_stat_destroy (¤t_stat_info); + xheader_destroy (&extended_header); } access_mode = ACCESS_WRITE; -- 2.45.2