From 883f2e6dcaf87b4b449e55ed4f08dda1e701dae7 Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Sun, 3 Mar 2024 13:27:32 -0800 Subject: [PATCH] tar: fix current_block confusion Problem reported by Robert Morris in: https://lists.gnu.org/r/bug-tar/2024-03/msg00001.html * src/delete.c (flush_file): Simply return at EOF, so that current_block continues to point to end of input. --- src/delete.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/delete.c b/src/delete.c index 4808a27b..8303415f 100644 --- a/src/delete.c +++ b/src/delete.c @@ -149,7 +149,7 @@ flush_file (void) flush_archive (); if (record_end == current_block) /* Hit EOF */ - break; + return; } current_block += blocks_to_skip; } -- 2.47.2