On Wed, Mar 24, 2010 at 09:04:19PM +0100, David Madore wrote: >Package: grep >Version: 2.5.4-4 > >Whether this is a bug is perhaps debatable (because of the vagueness >of specifications in the matter), and maybe needs to be discussed >upstream, but the following behavior is extremely confusing at the >very least: > >vega david ~ $ locale >LANG= >LC_CTYPE=en_US.UTF-8 >LC_NUMERIC="POSIX" >LC_TIME="POSIX" >LC_COLLATE="POSIX" >LC_MONETARY="POSIX" >LC_MESSAGES="POSIX" >LC_PAPER="POSIX" >LC_NAME="POSIX" >LC_ADDRESS="POSIX" >LC_TELEPHONE="POSIX" >LC_MEASUREMENT="POSIX" >LC_IDENTIFICATION="POSIX" >LC_ALL= >vega david ~ $ printf 'foobar\251\n' > /tmp/test >vega david ~ $ fgrep -q foobar /tmp/test >vega david ~ $ echo $? >0 >vega david ~ $ fgrep -q -i foobar /tmp/test >vega david ~ $ echo $? >1 >vega david ~ $ LC_CTYPE=C fgrep -q -i foobar /tmp/test >vega david ~ $ echo $? >0 > >I realize that "foobar\251\n" is not a well-formed utf-8 text file, so >fgrep is basically allowed to send daemons flying through my nose, but >I still think it is very wrong that fgrep -i foobar should not match a >file, be it binary, be it in a utf-8 locale, somehow containing the >string "foobar", especially as fgrep foobar and egrep -i foobar (and >egrep foobar) all match.
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=575300 Could someone please try to reproduce the bug above with grep 2.6. -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org