git log: avoid segfault with --all-match

Avoid a segfault when the command

	git log --all-match

was issued, by ignoring the option.

Signed-off-by: Michele Ballabio <barra_cuda@katamail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Michele Ballabio 2009-03-18 21:53:27 +01:00 committed by Junio C Hamano
parent 092927c1b0
commit ba150a3fdc

1
grep.c
View File

@ -192,6 +192,7 @@ void compile_grep_patterns(struct grep_opt *opt)
* A classic recursive descent parser would do.
*/
p = opt->pattern_list;
if (p)
opt->pattern_expression = compile_pattern_expr(&p);
if (p)
die("incomplete pattern expression: %s", p->pattern);