bugfindutils - Bugs: bug #12085, -printf pathname:%h/%f gives wrong...

 
 

bug #12085: -printf pathname:%h/%f gives wrong result

Submitter:  None
Submitted:  Tue 22 Feb 2005 06:56:42 AM UTC
   
 
Category:  find Severity:  3 - Normal
Item Group:  Wrong result Status:  Fixed
Privacy:  Public Assigned to:  jay
Originator Name:  Originator Email:  -email is unavailable-
Open/Closed:  Closed Release:  4.1.20
Fixed Release:  4.2.19
* Mandatory Fields

Add a New Comment Rich Markup
   

Thu 24 Feb 2005 09:49:05 AM UTC, comment #3: 

Thanks for such a quick reaction
--
vda

Anonymous
Wed 23 Feb 2005 12:32:48 AM UTC, comment #2: 

I've changed my mind.  "%h" now expands to "." instead of nothing when the matched file is in the current directory.   The documentation has been updated to make this clear.   The test suite also now contains a test for this case.

James Youngman <jay>
Group administrator
Tue 22 Feb 2005 07:01:04 PM UTC, comment #1: 

Fixed in CVS.  The result should now be

# find.fixed Makefile po/Makefile -printf 'pathname:%h/%f\n'
pathname:/Makefile
pathname:po/Makefile

Here %h expands to nothing where there is no slash in the filename.   That seems to me to be most consistent withthe documentation.

James Youngman <jay>
Group administrator
Tue 22 Feb 2005 06:56:42 AM UTC, original submission:  

Wrong result for files without slashes:

# find Makefile po/Makefile -printf 'pathname:%h/%f\n'
/Makefile  <===== ??!
pathname:po/Makefile

Patch fixes this:
# find.fixed Makefile po/Makefile -printf 'pathname:%h/%f\n'
pathname:./Makefile
pathname:po/Makefile

Anonymous

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

Attached Files
file #2606:  findutils-4.1.20.dirprintf.patch added by None (673B - application/octet-stream)

 

Depends on the following items: None found

Items that depend on this one: None found

 

CC list is empty

 

There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

Only logged-in users can vote.

 

Follow 6 latest changes.

Date Changed by Updated Field Previous Value => Replaced by
2005-03-07 jay Open/ClosedOpen Closed
    Fixed ReleaseNone 4.2.19
2005-02-22 jay StatusNone Fixed
    Assigned toNone jay
2005-02-22 None Attached File- Added findutils-4.1.20.dirprintf.patch, #2228
    Carbon-Copy- Added vda --AT-- ilport --DOT-- com --DOT-- ua

Back to the top

Powered by Savane 3.13-f8d8.
Corresponding source code