]> git.ipfire.org Git - thirdparty/git.git/commitdiff
Sync with Git 2.16.4
authorJunio C Hamano <gitster@pobox.com>
Tue, 22 May 2018 05:25:26 +0000 (14:25 +0900)
committerJunio C Hamano <gitster@pobox.com>
Tue, 22 May 2018 05:25:26 +0000 (14:25 +0900)
* maint-2.16:
  Git 2.16.4
  Git 2.15.2
  Git 2.14.4
  Git 2.13.7
  verify_path: disallow symlinks in .gitmodules
  update-index: stat updated files earlier
  verify_dotfile: mention case-insensitivity in comment
  verify_path: drop clever fallthrough
  skip_prefix: add case-insensitive variant
  is_{hfs,ntfs}_dotgitmodules: add tests
  is_ntfs_dotgit: match other .git files
  is_hfs_dotgit: match other .git files
  is_ntfs_dotgit: use a size_t for traversing string
  submodule-config: verify submodule names as paths

1  2 
apply.c
builtin/submodule--helper.c
builtin/update-index.c
cache.h
dir.c
git-compat-util.h
git-submodule.sh
read-cache.c

diff --cc apply.c
Simple merge
Simple merge
index 58d1c2d2827d61899d73f1ea7632c5ee219f3ace,52eaebae911ee3439f4464c9c317f1776f89c10a..1af8a00b889c968634389bf61138200d97eb32f9
@@@ -449,7 -448,17 +448,18 @@@ static void chmod_path(char flip, cons
  
  static void update_one(const char *path)
  {
-       if (!verify_path(path)) {
+       int stat_errno = 0;
+       struct stat st;
 -      if (mark_valid_only || mark_skip_worktree_only || force_remove)
++      if (mark_valid_only || mark_skip_worktree_only || force_remove ||
++          mark_fsmonitor_only)
+               st.st_mode = 0;
+       else if (lstat(path, &st) < 0) {
+               st.st_mode = 0;
+               stat_errno = errno;
+       } /* else stat is valid */
+       if (!verify_path(path, st.st_mode)) {
                fprintf(stderr, "Ignoring path %s\n", path);
                return;
        }
diff --cc cache.h
Simple merge
diff --cc dir.c
index dedbf5d476f207e39c1b7853ec8c97553181e5fb,7c4b45e30e0ac87527ff0ef3fd8c90670a1e2064..41aac3b7b38e76bb790da4c21c362d7d0f1d1a07
--- 1/dir.c
--- 2/dir.c
+++ b/dir.c
@@@ -2992,8 -2972,6 +2992,8 @@@ void untracked_cache_invalidate_path(st
  {
        if (!istate->untracked || !istate->untracked->root)
                return;
-       if (!safe_path && !verify_path(path))
++      if (!safe_path && !verify_path(path, 0))
 +              return;
        invalidate_one_component(istate->untracked, istate->untracked->root,
                                 path, strlen(path));
  }
Simple merge
Simple merge
diff --cc read-cache.c
Simple merge