]> Dogcows Code - chaz/tar/commitdiff
(read_and): Print block number before
authorSergey Poznyakoff <gray@gnu.org.ua>
Mon, 10 May 2004 11:41:23 +0000 (11:41 +0000)
committerSergey Poznyakoff <gray@gnu.org.ua>
Mon, 10 May 2004 11:41:23 +0000 (11:41 +0000)
issuing 'Skipping to next header' diagnostics, if
requested by block_number_option.

src/list.c

index eb5f9bac0602205e4c2629df397e2bf5d0441e5e..e2746bc72445676762fe215c8b391aa9b284d332 100644 (file)
@@ -171,6 +171,15 @@ read_and (void (*do_something) (void))
 
            case HEADER_ZERO_BLOCK:
            case HEADER_SUCCESS:
+             if (block_number_option)
+               {
+                 char buf[UINTMAX_STRSIZE_BOUND];
+                 off_t block_ordinal = current_block_ordinal ();
+                 block_ordinal -= recent_long_name_blocks;
+                 block_ordinal -= recent_long_link_blocks;
+                 fprintf (stdlis, _("block %s: "),
+                          STRINGIFY_BIGINT (block_ordinal, buf));
+               }
              ERROR ((0, 0, _("Skipping to next header")));
              break;
 
This page took 0.022912 seconds and 4 git commands to generate.