Sophie

Sophie

distrib > Scientific%20Linux > 5x > x86_64 > by-pkgid > 5b8b6132026058084c61b740d28c4765 > files > 13

tar-1.15.1-23.0.1.el5.src.rpm

--- tar-1.15.1/src/create.c.padCorrectly	2005-11-04 10:18:08.000000000 -0500
+++ tar-1.15.1/src/create.c	2005-11-04 10:21:05.000000000 -0500
@@ -877,8 +877,8 @@
 	  return dump_status_short;
 	}
       size_left -= count;
-
-      set_next_block_after (blk + (bufsize - 1) / BLOCKSIZE);
+      if (count)
+        set_next_block_after (blk + (bufsize - 1) / BLOCKSIZE);
 
       if (count != bufsize)
 	{
@@ -892,7 +892,7 @@
 		 STRINGIFY_BIGINT (size_left, buf)));
 	  if (! ignore_failed_read_option)
 	    exit_status = TAREXIT_FAILURE;
-	  pad_archive (size_left);
+	  pad_archive (size_left - (bufsize-count));
 	  return dump_status_short;
 	}
     }