From: Junio C Hamano Date: Mon, 17 Sep 2018 20:53:47 +0000 (-0700) Subject: Merge branch 'nd/clone-case-smashing-warning' X-Git-Tag: v2.20.0-rc0~256 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=c2407322b6f248955d8ce8d1d453f2dc1b03e618;p=git Merge branch 'nd/clone-case-smashing-warning' Running "git clone" against a project that contain two files with pathnames that differ only in cases on a case insensitive filesystem would result in one of the files lost because the underlying filesystem is incapable of holding both at the same time. An attempt is made to detect such a case and warn. * nd/clone-case-smashing-warning: clone: report duplicate entries on case-insensitive filesystems --- c2407322b6f248955d8ce8d1d453f2dc1b03e618 diff --cc unpack-trees.c index f25089b878,213da8bbb4..cfa88bb6ec --- a/unpack-trees.c +++ b/unpack-trees.c @@@ -413,7 -465,11 +456,11 @@@ static int check_updates(struct unpack_ stop_progress(&progress); errs |= finish_delayed_checkout(&state); if (o->update) - git_attr_set_direction(GIT_ATTR_CHECKIN, NULL); + git_attr_set_direction(GIT_ATTR_CHECKIN); + + if (o->clone) + report_collided_checkout(index); + return errs != 0; }