sbase

suckless unix tools
git clone git://git.2f30.org/sbase.git
Log | Files | Refs | README | LICENSE

commit 4b733abe99a7e4dfb6074639c6f276cd1783a0eb
parent 2b31049d009534fbf5d52d17a1463fe9dd32481b
Author: sin <sin@2f30.org>
Date:   Wed Jan 20 15:05:01 +0000

Revert "If we have a match any pattern also match against blank lines"

Doesn't really make sense for grep . to match blank lines.

Diffstat:
grep.c | 2+-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/grep.c b/grep.c @@ -115,7 +115,7 @@ grep(FILE *fp, const char *str) buf[len - 1] = '\0'; SLIST_FOREACH(pnode, &phead, entry) { if (!Fflag) { - if (regexec(&pnode->preg, buf[0] == '\0' ? "\n" : buf, 0, NULL, 0) ^ vflag) + if (regexec(&pnode->preg, buf, 0, NULL, 0) ^ vflag) continue; } else { if (!xflag) {