diff options
author | Junio C Hamano <gitster@pobox.com> | 2021-03-30 14:35:36 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2021-03-30 14:35:36 -0700 |
commit | 9210c68d2af84d869f1635efe9a2092578653297 (patch) | |
tree | 3967574291f29eca2c480266658e2d4185370d66 /entry.c | |
parent | 84d06cdc06389ae7c462434cb7b1db0980f63860 (diff) | |
parent | fab78a0c3defddff87ea5aa7dd32c5e444c43f1f (diff) | |
download | git-9210c68d2af84d869f1635efe9a2092578653297.tar.gz |
Merge branch 'mt/checkout-remove-nofollow'
When "git checkout" removes a path that does not exist in the
commit it is checking out, it wasn't careful enough not to follow
symbolic links, which has been corrected.
* mt/checkout-remove-nofollow:
checkout: don't follow symlinks when removing entries
symlinks: update comment on threaded_check_leading_path()
Diffstat (limited to 'entry.c')
-rw-r--r-- | entry.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -530,7 +530,7 @@ void unlink_entry(const struct cache_entry *ce) submodule_move_head(ce->name, "HEAD", NULL, SUBMODULE_MOVE_HEAD_FORCE); } - if (!check_leading_path(ce->name, ce_namelen(ce))) + if (check_leading_path(ce->name, ce_namelen(ce), 1) >= 0) return; if (remove_or_warn(ce->ce_mode, ce->name)) return; |