Subject: Re: Bug in grep 2.5.1a (+ patch to fix it)



On Wed, Apr 27, 2005 at 12:54:16PM +0100, Gordon Lack wrote:

> There is a bug in grep 2.5.1a (in fact all 2.5*) when you use the -F
> and -w options together (fixed strings, words only).

Confirmed. But:

> my-system*[1] cat test
> An unmatched line to make the file larger
> Match 2908
> An unmatched line to make the file larger
> Non-match 31560
> An unmatched line to make the file larger
> Match 3440
> An unmatched line to make the file larger
> Match 3156
> An unmatched line to make the file larger
>
> my-system*[1] grep -wF -e 2908 -e 3440 -e 3156 test
> Match 2908
>
>
> It gives only one match, but it should have given 3.

This example works fine with the patched grep that ships with Fedora
Core 3. Three matches are shown.

So this is already fixed by one of the pending patches.

Tim.
*/

Attachment: pgpmquZqHTT2e.pgp
Description: PGP signature

...



Privacy