Merge branch 'dk/format-patch-ignore-diff-submodule' into maint
authorJunio C Hamano <gitster@pobox.com>
Wed, 25 Feb 2015 06:10:15 +0000 (22:10 -0800)
committerJunio C Hamano <gitster@pobox.com>
Wed, 25 Feb 2015 06:10:15 +0000 (22:10 -0800)
Setting diff.submodule to 'log' made "git format-patch" produce
broken patches.

* dk/format-patch-ignore-diff-submodule:
format-patch: ignore diff.submodule setting
t4255: test am submodule with diff.submodule

1  2 
builtin/log.c
diff --combined builtin/log.c
index 923ffe72ced41f12a2258f732be418731bc2e4a8,cb14db48987247aae85f4891bd8fec324f709c56..a131992c52f96daeb7c72b447c5ed6929c01a96a
@@@ -38,8 -38,8 +38,8 @@@ static const char *fmt_patch_subject_pr
  static const char *fmt_pretty;
  
  static const char * const builtin_log_usage[] = {
 -      N_("git log [<options>] [<revision range>] [[--] <path>...]\n")
 -      N_("   or: git show [options] <object>..."),
 +      N_("git log [<options>] [<revision range>] [[--] <path>...]"),
 +      N_("git show [options] <object>..."),
        NULL
  };
  
@@@ -489,7 -489,7 +489,7 @@@ static int show_tag_object(const unsign
  }
  
  static int show_tree_object(const unsigned char *sha1,
 -              const char *base, int baselen,
 +              struct strbuf *base,
                const char *pathname, unsigned mode, int stage, void *context)
  {
        printf("%s%s\n", pathname, S_ISDIR(mode) ? "/" : "");
@@@ -705,7 -705,7 +705,7 @@@ static int git_format_config(const cha
                return 0;
        }
        if (!strcmp(var, "diff.color") || !strcmp(var, "color.diff") ||
-           !strcmp(var, "color.ui")) {
+           !strcmp(var, "color.ui") || !strcmp(var, "diff.submodule")) {
                return 0;
        }
        if (!strcmp(var, "format.numbered")) {