Bug 416661

Summary: Meaning of --occurrence wrong in man page
Product: [Fedora] Fedora Reporter: Jonathan Wakely <fedoration>
Component: tarAssignee: Radek Brich <rbrich>
Status: CLOSED CURRENTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: low Docs Contact:
Priority: low    
Version: 8   
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: 1.17-6.fc8 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2008-02-17 12:05:25 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:
Bug Depends On:    
Bug Blocks: 429522    
Attachments:
Description Flags
patch for tar.1 man page none

Description Jonathan Wakely 2007-12-08 18:04:00 UTC
Description of problem:
The man page shipped with RH/Fedora tar (which doesn't exist upstream) gives the
wrong semantics for --occurrence.  It claims --occurrence N will process the
first N occurrences, whereas it should be --occurrences=N and it only processes
the Nth, not 1-N.

Version-Release number of selected component (if applicable):
tar-1.17-4.fc8 and older versions

How reproducible:
Always

Steps to Reproduce:
Compare what "man tar" says about --occurrence with "info tar" or try this:

mkdir tmp || exit 
cd tmp
touch bug

tar cvf bugs.tar bug bug bug
tar --delete -f bugs.tar --occurrence 2 bug
tar tvf bugs.tar

tar cvf bugs.tar bug bug bug
tar --delete -f bugs.tar --occurrence=2 bug
tar tvf bugs.tar

none of the --delete commands do what you would expect from the man page.

Patch attached.

Comment 1 Jonathan Wakely 2007-12-08 18:04:00 UTC
Created attachment 282061 [details]
patch for tar.1 man page

Comment 2 Radek Brich 2008-01-21 12:34:36 UTC
It will be fixed in F8 and Fdevel. I also cloned this bug for RHEL5.
Thanks for reporting.

Comment 3 Fedora Update System 2008-01-22 15:39:28 UTC
tar-1.17-6.fc8 has been pushed to the Fedora 8 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update tar'