Bug 15448
Summary: | tar exit code is still incorrect | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Product: | [Retired] Red Hat Linux | Reporter: | mal | ||||||||
Component: | tar | Assignee: | Bernhard Rosenkraenzer <bero> | ||||||||
Status: | CLOSED RAWHIDE | QA Contact: | |||||||||
Severity: | medium | Docs Contact: | |||||||||
Priority: | medium | ||||||||||
Version: | 7.0 | CC: | dkl, twaugh | ||||||||
Target Milestone: | --- | ||||||||||
Target Release: | --- | ||||||||||
Hardware: | i386 | ||||||||||
OS: | Linux | ||||||||||
Whiteboard: | |||||||||||
Fixed In Version: | Doc Type: | Bug Fix | |||||||||
Doc Text: | Story Points: | --- | |||||||||
Clone Of: | Environment: | ||||||||||
Last Closed: | 2000-09-23 17:27:45 UTC | Type: | --- | ||||||||
Regression: | --- | Mount Type: | --- | ||||||||
Documentation: | --- | CRM: | |||||||||
Verified Versions: | Category: | --- | |||||||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||||||
Cloudforms Team: | --- | Target Upstream Version: | |||||||||
Embargoed: | |||||||||||
Attachments: |
|
Description
mal
2000-08-04 21:22:38 UTC
verified behavior ... thanks for the report! Created attachment 2176 [details]
Here is a patch that fixes it for me.
The patch looks ok - applied it. *** Bug 11714 has been marked as a duplicate of this bug. *** tar-1.13.17-7 does not work for me. [root@test176 /root]# tar czvvf /dev/st0 /tmp/install.log tar: Removing leading `/' from member names -rw-r--r-- root/root 18419 2000-08-15 05:17:59 tmp/install.log [root@test176 /root]# tar (grandchild): /dev/st0: Cannot open: No such device tar (grandchild): Error is not recoverable: exiting now echo $? 0 [root@test176 /root]# Notice the prompt in the middle of the tar messages. Notice the return code. Still has a good return. I've reopened the problem. Created attachment 2525 [details]
This is a letter from Paul Eggert (tar mantainer), it should help.
Everything works OK with this new buffer.c file from Paul Eggert -- With new buffer.c ---- ./tar zcvf /dev/st0 /tmp/AAA ./tar: Removing leading `/' from member names tmp/AAA tar (child): /dev/st0: Cannot open: No such device tar (child): Error is not recoverable: exiting now ./tar: Child returned status 2 ./tar: Error exit delayed from previous errors [root@eth0_extrenal src]# echo $? 2 I post Paul Eggert comments in regards with new buffer.c ============================================================= Date: Tue, 15 Aug 2000 17:20:25 -0700 (PDT) From: Paul Eggert <eggert> Message-Id: <200008160020.RAA05399.com> To: vmalyshkin In-reply-to: <399982E3.C67BFE9D> (vmalyshkin) Subject: Re: Bug with tar exit code References: <3999469A.5B1A644A> <200008152127.OAA02934.com> <399982E3.C67BFE9D> Date: Tue, 15 Aug 2000 13:50:27 -0400 From: Vladislav Malyshkin <vmalyshkin> Would you recomend to use this buffer.c file for next RedHat? Sorry, I don't have time to think through all the changes right now. But I would say that if you limit it only to the changes related to child processes, it would be reasonable to recommend it. ============================================================= Also, if you do diff in between new and old buffer.c the other changes are really minor. Mostly comments changes and little cleanup, line using assign_string instad of strcpy It looks like new buffer.c can go as is. Also, it may not be clear, comments after ==================== belong to me, not to Paul Can this bug be fixed before the relase, the fix is provided in second attachment. It's fixed in the internal tree, waiting for QA approval The package ftp://ftp.redhat.com/pub/rawhide/SRPMS/SRPMS/tar-1.13.17-7.src.rpm from current rawhide does not fix the problem. It uses pach from (id=2176) which does not fix exit code problem. Use the fix from attachment (id=2525) which really solves the problem. I know - this patch is in 1.13-8, which has been in the internal tree for a while. It's fixed for 7.0. Oops, make that 1.13.17-8 (id=2525) may fix the exit code problem, but now gives far worse behaviour: tar zvt < test.tgz now hangs. :-((( I'll attach a tentative fix. Created attachment 3522 [details]
Fix for 'tar hangs' problem
Fixed in -9 |