From: Junio C Hamano Date: Thu, 16 Mar 2017 20:56:43 +0000 (-0700) Subject: Merge branch 'js/realpath-pathdup-fix' into maint X-Git-Tag: v2.12.1~2 X-Git-Url: https://git.lorimer.id.au/gitweb.git/diff_plain/2846ef3e27ff0e34812dad788b706f0a1e5b5e80 Merge branch 'js/realpath-pathdup-fix' into maint 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. ... and then to down to 'maint'. * 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 --- 2846ef3e27ff0e34812dad788b706f0a1e5b5e80 diff --cc transport.c index d72e089484,d72e089484..b6c5652d6c --- a/transport.c +++ b/transport.c @@@ -1221,7 -1221,7 +1221,7 @@@ static int refs_from_alternate_cb(struc const struct ref *extra; struct alternate_refs_data *cb = data; -- other = real_pathdup(e->path); ++ other = real_pathdup(e->path, 1); len = strlen(other); while (other[len-1] == '/')