bug-gnu-utils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug in grep -F -w


From: Steve Keay
Subject: bug in grep -F -w
Date: Tue, 6 May 2003 15:58:46 +0100
User-agent: Mutt/1.2.5.1i

I've found a problem where fgrep -w fails to match words if an earlier
line of input contains the search string.  In the following example,
grep fails to match "bug" on the second line of input.  This is caused
by the first line of input which contains "bug" as a substring.

This problem has been reproduced with grep built from source on
Solaris and Linux.

$ cat words
bugs
bug
$ grep -F -w bug words
$ grep --version
grep (GNU grep) 2.5.1

Copyright 1988, 1992-1999, 2000, 2001 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

Regards,
-- 
Steve Keay




reply via email to

[Prev in Thread] Current Thread [Next in Thread]