]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
zgrep: fix exit status with multiple files
authorvangyzen <vangyzen@FreeBSD.org>
Thu, 1 Oct 2020 21:48:22 +0000 (21:48 +0000)
committervangyzen <vangyzen@FreeBSD.org>
Thu, 1 Oct 2020 21:48:22 +0000 (21:48 +0000)
commit72799201e430b484681abd204e2eee1824d8f68b
tree3d5efee44aa41a41cebb8a303dc2ab96abfff9eb
parent3c1e65dae908bac739eedb5a17bf77046d73bf0a
zgrep: fix exit status with multiple files

zgrep should exit with success when given multiple files and the
pattern is found in at least one file.  Prior to this change,
it would exit with success only if the pattern was found in _every_ file.

Reviewed by: dab ngie
MFC after: 2 weeks
Sponsored by: Dell EMC Isilon
Differential Revision: https://reviews.freebsd.org/D26616
contrib/netbsd-tests/usr.bin/grep/t_grep.sh
usr.bin/grep/zgrep.sh