summaryrefslogtreecommitdiff
path: root/worktree.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2017-03-13 06:21:33 (GMT)
committerJunio C Hamano <gitster@pobox.com>2017-03-13 06:21:33 (GMT)
commitba37c92df905a5bc51efe76e32f0e67c4ad5acbe (patch)
treea01300f6b0ae623259f04aa38cca91f6f5f81047 /worktree.c
parentfb070d2f17b0619cbc1be0606fd452b2294abb8d (diff)
parentce83eadd9a2c63db6263df91933da1b1b865d26a (diff)
downloadgit-ba37c92df905a5bc51efe76e32f0e67c4ad5acbe.zip
git-ba37c92df905a5bc51efe76e32f0e67c4ad5acbe.tar.gz
git-ba37c92df905a5bc51efe76e32f0e67c4ad5acbe.tar.bz2
Merge branch 'js/realpath-pathdup-fix'
Git v2.12 was shipped with an embarrassing breakage where various operations that verify paths given from the user stopped dying when seeing an issue, and instead later triggering segfault. * js/realpath-pathdup-fix: real_pathdup(): fix callsites that wanted it to die on error t1501: demonstrate NULL pointer access with invalid GIT_WORK_TREE
Diffstat (limited to 'worktree.c')
-rw-r--r--worktree.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/worktree.c b/worktree.c
index d7b911a..fa7bc67 100644
--- a/worktree.c
+++ b/worktree.c
@@ -255,7 +255,7 @@ struct worktree *find_worktree(struct worktree **list,
return wt;
arg = prefix_filename(prefix, strlen(prefix), arg);
- path = real_pathdup(arg);
+ path = real_pathdup(arg, 1);
for (; *list; list++)
if (!fspathcmp(path, real_path((*list)->path)))
break;