[ARVADOS] updated: 178d3f36265e0e9e9cc0bb6ac8c7c47a9c701687

git at public.curoverse.com git at public.curoverse.com
Fri May 29 22:10:52 EDT 2015


Summary of changes:
 sdk/cli/bin/crunch-job | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

       via  178d3f36265e0e9e9cc0bb6ac8c7c47a9c701687 (commit)
      from  9413eb733015601af699f2027d9a7a5bad3f3dea (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.


commit 178d3f36265e0e9e9cc0bb6ac8c7c47a9c701687
Author: Tom Clegg <tom at curoverse.com>
Date:   Fri May 29 22:01:06 2015 -0400

    Tell tar to read to EOF (even if it detects trailing NULs).
    
    Avoids SIGPIPE when feeding a tarball made with tar -A.
    
    refs #6146 refs #6094

diff --git a/sdk/cli/bin/crunch-job b/sdk/cli/bin/crunch-job
index 864e3c0..76eb95d 100755
--- a/sdk/cli/bin/crunch-job
+++ b/sdk/cli/bin/crunch-job
@@ -2087,7 +2087,12 @@ do {
   # Ignore SIGPIPE: we check retval of close() instead. See perlipc(1).
   local $SIG{PIPE} = "IGNORE";
   warn "Extracting archive: $archive_hash\n";
-  if (!open(TARX, "|-", "tar", "-xC", $destdir)) {
+  # --ignore-zeros is necessary sometimes: depending on how much NUL
+  # padding tar -A put on our combined archive (which in turn depends
+  # on the length of the component archives) tar without
+  # --ignore-zeros will exit before consuming stdin and cause close()
+  # to fail on the resulting SIGPIPE.
+  if (!open(TARX, "|-", "tar", "--ignore-zeros", "-xC", $destdir)) {
     die "Error launching 'tar -xC $destdir': $!";
   }
   # If we send too much data to tar in one write (> 4-5 MiB), it stops, and we

-----------------------------------------------------------------------


hooks/post-receive
-- 




More information about the arvados-commits mailing list