rev-list: fix segfault with --{author,committer,grep}
authorJeff King <peff@peff.net>
Mon, 18 Sep 2006 06:52:42 +0000 (02:52 -0400)
committerJunio C Hamano <junkio@cox.net>
Wed, 20 Sep 2006 18:14:39 +0000 (11:14 -0700)
We need to save the commit buffer if we're going to match against it.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <junkio@cox.net>
builtin-rev-list.c

index 1f3333da38c77a07840a8dfad052c301dbae9392..dbfee750aace175bd8d06fb3e7d1f6d0083c163e 100644 (file)
@@ -269,7 +269,9 @@ int cmd_rev_list(int argc, const char **argv, const char *prefix)
            revs.diff)
                usage(rev_list_usage);
 
-       save_commit_buffer = revs.verbose_header;
+       save_commit_buffer = revs.verbose_header ||
+               revs.header_filter ||
+               revs.message_filter;
        track_object_refs = 0;
        if (bisect_list)
                revs.limited = 1;