Code

git-merge: add --ff and --no-ff options
[git.git] / builtin-archive.c
index e221f115f9f1a214d5507777d191a81850835385..a90c65ce54a1c3e415b46465a2b4c7bfdffca9ff 100644 (file)
@@ -108,6 +108,7 @@ static void *format_subst(const struct commit *commit, const char *format,
 
                formatted_len = format_commit_message(commit, fmt, &formatted,
                                                      &allocated);
+               free(fmt);
                result = xrealloc(result, result_len + a_len + formatted_len);
                memcpy(result + result_len, a, a_len);
                memcpy(result + result_len + a_len, formatted, formatted_len);