]> Dogcows Code - chaz/tar/commitdiff
(xhdr_tab): New keyword GNU.volume.filename.
authorSergey Poznyakoff <gray@gnu.org.ua>
Thu, 10 Nov 2005 12:59:38 +0000 (12:59 +0000)
committerSergey Poznyakoff <gray@gnu.org.ua>
Thu, 10 Nov 2005 12:59:38 +0000 (12:59 +0000)
src/xheader.c

index 965ef160debdb29f2e93f7a49293cb6eb5e1a5ec..37bcdc1d7c1b9ed84049b324897074a62eb5c373 100644 (file)
@@ -1317,7 +1317,7 @@ volume_size_decoder (struct tar_stat_info *st, char const *arg, size_t size)
 /* FIXME: Merge with volume_size_coder */
 static void
 volume_offset_coder (struct tar_stat_info const *st, char const *keyword,
-                  struct xheader *xhdr, void const *data)
+                    struct xheader *xhdr, void const *data)
 {
   off_t v = *(off_t*)data;
   code_num (v, keyword, xhdr);
@@ -1331,6 +1331,14 @@ volume_offset_decoder (struct tar_stat_info *st, char const *arg, size_t size)
     continued_file_offset = u;
 }
 
+static void
+volume_filename_decoder (struct tar_stat_info *st, char const *arg,
+                        size_t size)
+{
+  decode_string (&continued_file_name, arg);
+}
+  
+
 struct xhdr_tab const xhdr_tab[] = {
   { "atime",   atime_coder,    atime_decoder,    false },
   { "comment", dummy_coder,    dummy_decoder,    false },
@@ -1374,8 +1382,10 @@ struct xhdr_tab const xhdr_tab[] = {
      otherwise kept in the size field of a multivolume header.  The
      GNU.volume.offset keeps the offset of the start of this volume,
      otherwise kept in oldgnu_header.offset.  */
-  { "GNU.volume.size", volume_size_coder, volume_size_decoder, false },
-  { "GNU.volume.offset", volume_offset_coder, volume_offset_decoder, false },
+  { "GNU.volume.filename", volume_label_coder, volume_filename_decoder,
+    true },
+  { "GNU.volume.size", volume_size_coder, volume_size_decoder, true },
+  { "GNU.volume.offset", volume_offset_coder, volume_offset_decoder, true },
 
   { NULL, NULL, NULL, false }
 };
This page took 0.025613 seconds and 4 git commands to generate.