summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLibravatar Junio C Hamano <gitster@pobox.com>2019-07-29 12:38:11 -0700
committerLibravatar Junio C Hamano <gitster@pobox.com>2019-07-29 12:38:11 -0700
commit58f6cfd8ce3c4621d4a772b81b7c92f7519154f1 (patch)
treed32b6120fb20627d449f0de0a43a2a8ba84ba432
parentMerge branch 'js/gcc-8-and-9' into maint (diff)
parentdiff: munmap() file contents before running external diff (diff)
downloadtgif-58f6cfd8ce3c4621d4a772b81b7c92f7519154f1.tar.xz
Merge branch 'js/unmap-before-ext-diff' into maint
Windows update. * js/unmap-before-ext-diff: diff: munmap() file contents before running external diff
-rw-r--r--diff.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/diff.c b/diff.c
index a654d46f6a..1ccd96bbfd 100644
--- a/diff.c
+++ b/diff.c
@@ -4206,6 +4206,8 @@ static void run_external_diff(const char *pgm,
argv_array_pushf(&env, "GIT_DIFF_PATH_COUNTER=%d", ++o->diff_path_counter);
argv_array_pushf(&env, "GIT_DIFF_PATH_TOTAL=%d", q->nr);
+ diff_free_filespec_data(one);
+ diff_free_filespec_data(two);
if (run_command_v_opt_cd_env(argv.argv, RUN_USING_SHELL, NULL, env.argv))
die(_("external diff died, stopping at %s"), name);