summaryrefslogtreecommitdiff
path: root/grep.c
diff options
context:
space:
mode:
Diffstat (limited to 'grep.c')
-rw-r--r--grep.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/grep.c b/grep.c
index 6e085f8297..f486ee5631 100644
--- a/grep.c
+++ b/grep.c
@@ -1622,6 +1622,8 @@ static int chk_hit_marker(struct grep_expr *x)
int grep_source(struct grep_opt *opt, struct grep_source *gs)
{
+ if(opt->none_match)
+ return !grep_source_1(opt, gs, 0);
/*
* we do not have to do the two-pass grep when we do not check
* buffer-wide "all-match".