bugfindutils - Bugs: bug #18714, <VT> and <FF> also...

 
 

bug #18714: <VT> and <FF> also seen as separators by GNU xargs

Submitted by:  None
Submitted on:  Sat 06 Jan 2007 08:51:03 PM UTC  
 
Category:  xargs Severity:  3 - Normal
Item Group:  Wrong result Status:  Fixed
Privacy:  Public Assigned to:  James Youngman <jay>
Originator Name:  Stephane Chazelas Originator Email:  -email is unavailable-
Open/Closed:  Closed Release:  4.2.29
Fixed Release:  4.3.3

Add a New Comment (Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Sat 13 Jan 2007 06:49:25 PM UTC, comment #2: 

Fixed in the findutils-4.3.x CVS codebase.

This problem is fixed in the CVS code for findutils.
To resolve your problem, you could either wait for the
next official release of findutils, or check out a copy
of the code from the CVS repository for findutils.

James Youngman <jay>
Project AdministratorIn charge of this item.
Sun 07 Jan 2007 06:19:45 PM UTC, comment #1: 

POSIX insicates that arguments are separated by <blank>s and defines a <blank> as...

One of the characters that belong to the blank character class as defined via the LC_CTYPE category in the current locale. In the POSIX locale, a <blank> is either a <tab> or a <space>.

Hence there is certainly a bug.  I think the problem is just that xargs.c uses ISSPACE() on line 831 of the current CVS code when it should in fact call ISBLANK().

James Youngman <jay>
Project AdministratorIn charge of this item.
Sat 06 Jan 2007 08:51:03 PM UTC, original submission:  

xargs is meant to only recognise blanks, that is <SPC>, <NL> and <TAB> as separators in the arguments it receives on input.

GNU xargs happens to also treat all the other space characters (vertical tab (\v), carriage return (\r), form feed (\f)) as separators which is wrong.

~$ printf '\f\r\va' | xargs printf %s | od -tc

              1.   a

0000001

Should output instead:

~$ printf '\f\r\va' | od -tc

              1. \f  \r  \v   a

0000004

Anonymous

 

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

Attach Files:
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by jay (Posted a comment)
  •  

    Do you think this task is very important?
    If so, you can add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

     

     

    Follow 5 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2007-04-15 jay Open/ClosedOpen => Closed
        Fixed ReleaseNone => 4.3.3
    2007-01-13 jay StatusIn Progress => Fixed
    2007-01-07 jay StatusNone => In Progress
        Assigned toNone => jay

    Back to the top


    Powered by Savane 3.5