Fix git {log,show,...} --pretty=email
authorJunio C Hamano <junkio@cox.net>
Thu, 12 Apr 2007 10:04:05 +0000 (03:04 -0700)
committerJunio C Hamano <junkio@cox.net>
Fri, 13 Apr 2007 00:43:28 +0000 (17:43 -0700)
An earlier --subject-prefix patch forgot that format-patch is
not the only codepath that adds the "[PATCH]" prefix, and broke
everybody else in the log family.

Signed-off-by: Junio C Hamano <junkio@cox.net>
builtin-log.c
revision.c

index 4a4890aca0ac085a68ca86100a5441317b5be8d4..ffc269a1225b5ee51e75416a5d501a541342b46f 100644 (file)
@@ -435,7 +435,6 @@ int cmd_format_patch(int argc, const char **argv, const char *prefix)
        rev.ignore_merges = 1;
        rev.diffopt.msg_sep = "";
        rev.diffopt.recursive = 1;
-       rev.subject_prefix = "PATCH";
 
        rev.extra_headers = extra_headers;
 
index 486393cb0835ce70f685d665b916e1b67974f184..37f1eab9e56ee6e725dfd2a29c95f2a4f1f15621 100644 (file)
@@ -567,6 +567,7 @@ void init_revisions(struct rev_info *revs, const char *prefix)
        revs->min_age = -1;
        revs->skip_count = -1;
        revs->max_count = -1;
+       revs->subject_prefix = "PATCH";
 
        revs->prune_fn = NULL;
        revs->prune_data = NULL;