Skip to content
Permalink
Browse files

Merge pull request #2026 from gitster/kg/external-diff-save-env

diff: ensure correct lifetime of external_diff_cmd
  • Loading branch information...
dscho committed Jan 16, 2019
2 parents 6b28658 + 6776a84 commit 4d3be1d845c107743543f6ce05b873f17c30fd3a
Showing with 1 addition and 1 deletion.
  1. +1 −1 diff.c
2 diff.c
@@ -489,7 +489,7 @@ static const char *external_diff(void)

if (done_preparing)
return external_diff_cmd;
external_diff_cmd = getenv("GIT_EXTERNAL_DIFF");
external_diff_cmd = xstrdup_or_null(getenv("GIT_EXTERNAL_DIFF"));
if (!external_diff_cmd)
external_diff_cmd = external_diff_cmd_cfg;
done_preparing = 1;

0 comments on commit 4d3be1d

Please sign in to comment.
You can’t perform that action at this time.