bsdgrep-20110912: -F/fgrep enbug
Hi,
I found another issue, this time in bsdgrep-20110912 in port.
==
#! /bin/sh
echo 1
echo 90123456789.|grep -F 0123456789.
echo 2
echo 90123456789.|grep 0123456789.
echo 3
echo 0123456789.|grep -F 0123456789.
echo 4
echo 90123456789.|grep -F 0123456789
echo 5
echo 90123456789x|grep -F 0123456789x
==
result:
1
2
90123456789.
3
0123456789.
4
90123456789.
5
90123456789x
==
(1) this should match but does not.
(2) without -F it matches.
(3) trim leading 1 byte from input string it matches.
(4) trim last period from query string it matches.
(5) replace period with another character (no matter what it is) it matches.
bsdgrep in -CURRENT and GNU grep match all cases.
--
kuro
_______________________________________________
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to "freebsd-current-unsubscribe@freebsd.org"
討論串 (同標題文章)