]> Dogcows Code - chaz/tar/blobdiff - src/buffer.c
(dump_file0): Use sys_stat_nanoseconds().
[chaz/tar] / src / buffer.c
index f451413e8e8d61703e644e3153401ecc6f329b1a..515c3b9aac07ffed35f7eea38fb7ceb832ddef08 100644 (file)
@@ -266,7 +266,7 @@ open_archive (enum access_mode wanted_access)
   if (archive_names == 0)
     FATAL_ERROR ((0, 0, _("No archive name given")));
 
-  destroy_stat (&current_stat_info);
+  tar_stat_destroy (&current_stat_info);
   save_name = 0;
   real_s_name = 0;
 
@@ -420,7 +420,7 @@ open_archive (enum access_mode wanted_access)
 
          record_start->header.typeflag = GNUTYPE_VOLHDR;
          TIME_TO_CHARS (start_time, record_start->header.mtime);
-         finish_header (record_start, -1);
+         finish_header (&current_stat_info, record_start, -1);
 #if 0
          current_block++;
 #endif
@@ -512,7 +512,7 @@ flush_write (void)
               volume_label_option, volno);
       TIME_TO_CHARS (start_time, record_start->header.mtime);
       record_start->header.typeflag = GNUTYPE_VOLHDR;
-      finish_header (record_start, -1);
+      finish_header (&current_stat_info, record_start, -1);
     }
 
   if (real_s_name)
@@ -535,7 +535,7 @@ flush_write (void)
                    record_start->oldgnu_header.offset);
       tmp = verbose_option;
       verbose_option = 0;
-      finish_header (record_start, -1);
+      finish_header (&current_stat_info, record_start, -1);
       verbose_option = tmp;
 
       if (volume_label_option)
@@ -623,8 +623,15 @@ short_read (ssize_t status)
          archive_read_error ();
 
       if (status == 0)
-       break;
-
+       {
+         char buf[UINTMAX_STRSIZE_BOUND];
+         
+         WARN((0, 0, _("Read %s bytes from %s"),
+               STRINGIFY_BIGINT (record_size - left, buf),
+               *archive_name_cursor));
+         break;
+       }
+  
       if (! read_full_records_option)
        {
          unsigned long rest = record_size - left;
@@ -913,7 +920,7 @@ close_archive (void)
 
   sys_wait_for_child (child_pid);
   
-  destroy_stat (&current_stat_info);
+  tar_stat_destroy (&current_stat_info);
   if (save_name)
     free (save_name);
   if (real_s_name)
This page took 0.025425 seconds and 4 git commands to generate.