summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 4b7acc1)
raw | patch | inline | side by side (parent: 4b7acc1)
author | René Scharfe <rene.scharfe@lsrfire.ath.cx> | |
Wed, 3 Feb 2010 18:16:30 +0000 (19:16 +0100) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Wed, 3 Feb 2010 20:03:40 +0000 (12:03 -0800) |
After 885d211e, the value of the ->fixed pattern option only depends on
the grep option of the same name. Regex flags don't matter any more,
because fixed mode and regex mode are strictly separated. Thus we can
simply copy the value from struct grep_opt to struct grep_pat, as we do
already for ->word_regexp and ->ignore_case.
Signed-off-by: Rene Scharfe <rene.scharfe@lsrfire.ath.cx>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
the grep option of the same name. Regex flags don't matter any more,
because fixed mode and regex mode are strictly separated. Thus we can
simply copy the value from struct grep_opt to struct grep_pat, as we do
already for ->word_regexp and ->ignore_case.
Signed-off-by: Rene Scharfe <rene.scharfe@lsrfire.ath.cx>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
grep.c | patch | blob | history |
index 60cce469f3be7c812bf24c4534e7321207b73a24..a0864f1cbbe5fcc6f28eb57a08ebfd9a76c87da6 100644 (file)
--- a/grep.c
+++ b/grep.c
p->word_regexp = opt->word_regexp;
p->ignore_case = opt->ignore_case;
+ p->fixed = opt->fixed;
- if (opt->fixed)
- p->fixed = 1;
- if (opt->regflags & REG_ICASE)
- p->fixed = 0;
if (p->fixed)
return;