[Bug 195763] bsdgrep, empty matches and -o

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Fri Jan 20 14:03:46 UTC 2017


https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=195763

--- Comment #2 from Kyle Evans <bsdports at kyle-evans.net> ---
(In reply to Kyle Evans from comment #1)

The 'ignore invalid patterns' change my previous patch makes seems definitively
wrong -- I'll have to revise this part and I'm just going to leave this here:

$ echo 'test' | grep ''
test
$ echo 'test' | grep -o ''
$ echo 'test' | bsdgrep ''
test
$ echo 'test' | bsdgrep -o ''

The regex bits declare this as a 4-character match, not sure off-hand how to
treat this but I don't believe ignoring the pattern is the right thing to do.

-- 
You are receiving this mail because:
You are the assignee for the bug.


More information about the freebsd-bugs mailing list