]> git.pld-linux.org Git - packages/tar.git/blob - tar-pipe.patch
- update for 1.13
[packages/tar.git] / tar-pipe.patch
1 diff -ur tar-1.13.orig/src/buffer.c tar-1.13/src/buffer.c
2 --- tar-1.13.orig/src/buffer.c  Mon Jul  5 08:47:59 1999
3 +++ tar-1.13/src/buffer.c       Wed Aug 25 22:18:55 1999
4 @@ -893,6 +893,7 @@
5  {
6    int copy_back;
7    ssize_t status;
8 +  int written;
9  
10    if (checkpoint_option && !(++checkpoint % 10))
11      WARN ((0, 0, _("Write checkpoint %d"), checkpoint));
12 @@ -905,6 +906,15 @@
13      }
14    else if (dev_null_output)
15      status = record_size;
16 +  else if (S_ISFIFO(archive_stat.st_mode)) {/*ppe: fix writing over a pipe */
17 +    status=0;
18 +    written=0;
19 +    while (status != record_size && written >=0 ) {
20 +      written=rmtwrite (archive, record_start->buffer+status,
21 +                      (unsigned int) (record_size-status));
22 +      if (written>=0) status += written;
23 +    }
24 +  }
25    else
26      status = write_archive_buffer ();
27    if (status != record_size && !multi_volume_option)
This page took 0.028351 seconds and 3 git commands to generate.