]> git.ipfire.org Git - thirdparty/git.git/commitdiff
Sync with v1.9.5
authorJunio C Hamano <gitster@pobox.com>
Wed, 17 Dec 2014 19:28:02 +0000 (11:28 -0800)
committerJunio C Hamano <gitster@pobox.com>
Wed, 17 Dec 2014 19:28:54 +0000 (11:28 -0800)
* maint-1.9:
  Git 1.9.5
  Git 1.8.5.6
  fsck: complain about NTFS ".git" aliases in trees
  read-cache: optionally disallow NTFS .git variants
  path: add is_ntfs_dotgit() helper
  fsck: complain about HFS+ ".git" aliases in trees
  read-cache: optionally disallow HFS+ .git variants
  utf8: add is_hfs_dotgit() helper
  fsck: notice .git case-insensitively
  t1450: refactor ".", "..", and ".git" fsck tests
  verify_dotfile(): reject .git case-insensitively
  read-tree: add tests for confusing paths like ".." and ".git"
  unpack-trees: propagate errors adding entries to the index

12 files changed:
1  2 
Documentation/config.txt
Documentation/git.txt
cache.h
config.c
config.mak.uname
environment.c
fsck.c
path.c
read-cache.c
t/test-lib.sh
unpack-trees.c
utf8.c

Simple merge
index cd509775ad71608921d5a72d4b34f09c9930c30f,d092ce5684dcc931e43dad0ab431cc5b12f2dd0d..aa5b268e003ccab7f423a02d3f5db7f3cedd3657
@@@ -43,18 -43,10 +43,19 @@@ unreleased) version of Git, that is ava
  branch of the `git.git` repository.
  Documentation for older releases are available here:
  
- * link:v1.9.4/git.html[documentation for release 1.9.4]
 +* link:v2.0.4/git.html[documentation for release 2.0.4]
 +
 +* release notes for
 +  link:RelNotes/2.0.4.txt[2.0.4],
 +  link:RelNotes/2.0.3.txt[2.0.3],
 +  link:RelNotes/2.0.2.txt[2.0.2],
 +  link:RelNotes/2.0.1.txt[2.0.1],
 +  link:RelNotes/2.0.0.txt[2.0.0].
 +
+ * link:v1.9.5/git.html[documentation for release 1.9.5]
  
  * release notes for
+   link:RelNotes/1.9.5.txt[1.9.5],
    link:RelNotes/1.9.4.txt[1.9.4],
    link:RelNotes/1.9.3.txt[1.9.3],
    link:RelNotes/1.9.2.txt[1.9.2],
diff --cc cache.h
Simple merge
diff --cc config.c
Simple merge
index 7846bd76573fe2513f08a824e89938deae6543de,f3cdcbcddf49441fa181e2bcdb60fbe8368db6b2..aba56dcfad74919491360d0914d1390a9cbba110
@@@ -358,9 -367,10 +359,10 @@@ ifeq ($(uname_S),Windows
                compat/win32/dirent.o
        COMPAT_CFLAGS = -D__USE_MINGW_ACCESS -DNOGDI -DHAVE_STRING_H -DHAVE_ALLOCA_H -Icompat -Icompat/regex -Icompat/win32 -DSTRIP_EXTENSION=\".exe\"
        BASIC_LDFLAGS = -IGNORE:4217 -IGNORE:4049 -NOLOGO -SUBSYSTEM:CONSOLE -NODEFAULTLIB:MSVCRT.lib
 -      EXTLIBS = user32.lib advapi32.lib shell32.lib wininet.lib ws2_32.lib
 +      EXTLIBS = user32.lib advapi32.lib shell32.lib wininet.lib ws2_32.lib invalidcontinue.obj
        PTHREAD_LIBS =
        lib =
+       BASIC_CFLAGS += -DPROTECT_NTFS_DEFAULT=1
  ifndef DEBUG
        BASIC_CFLAGS += -GL -Os -MT
        BASIC_LDFLAGS += -LTCG
diff --cc environment.c
Simple merge
diff --cc fsck.c
index a7233c8d0b20c06f0aebffbec9c11dacb22b6769,ee7f531e36212a492851565f1bbb56c566039104..5e6723d410532a6e8eec100c524d4e4c24d4a4f4
--- 1/fsck.c
--- 2/fsck.c
+++ b/fsck.c
@@@ -165,12 -166,19 +166,14 @@@ static int fsck_tree(struct tree *item
  
                sha1 = tree_entry_extract(&desc, &name, &mode);
  
 -              if (is_null_sha1(sha1))
 -                      has_null_sha1 = 1;
 -              if (strchr(name, '/'))
 -                      has_full_path = 1;
 -              if (!*name)
 -                      has_empty_name = 1;
 -              if (!strcmp(name, "."))
 -                      has_dot = 1;
 -              if (!strcmp(name, ".."))
 -                      has_dotdot = 1;
 -              if (!strcasecmp(name, ".git") || is_hfs_dotgit(name) ||
 -                              is_ntfs_dotgit(name))
 -                      has_dotgit = 1;
 +              has_null_sha1 |= is_null_sha1(sha1);
 +              has_full_path |= !!strchr(name, '/');
 +              has_empty_name |= !*name;
 +              has_dot |= !strcmp(name, ".");
 +              has_dotdot |= !strcmp(name, "..");
-               has_dotgit |= !strcmp(name, ".git");
++              has_dotgit |= (!strcmp(name, ".git") ||
++                             is_hfs_dotgit(name) ||
++                             is_ntfs_dotgit(name));
                has_zero_pad |= *(char *)desc.buffer == '0';
                update_tree_entry(&desc);
  
diff --cc path.c
Simple merge
diff --cc read-cache.c
Simple merge
diff --cc t/test-lib.sh
Simple merge
diff --cc unpack-trees.c
index 97fc9954672f2c374541cad827bb5c459abebcdc,ca7dd0fa5fee1baeb18f5134fced98c933f585b1..02f69aeea3dc2e60336fa4ac018ec14ae10f911e
@@@ -102,17 -102,18 +102,17 @@@ void setup_unpack_trees_porcelain(struc
                opts->unpack_rejects[i].strdup_strings = 1;
  }
  
- static void do_add_entry(struct unpack_trees_options *o, struct cache_entry *ce,
+ static int do_add_entry(struct unpack_trees_options *o, struct cache_entry *ce,
                         unsigned int set, unsigned int clear)
  {
 -      clear |= CE_HASHED | CE_UNHASHED;
 +      clear |= CE_HASHED;
  
        if (set & CE_REMOVE)
                set |= CE_WT_REMOVE;
  
 -      ce->next = NULL;
        ce->ce_flags = (ce->ce_flags & ~clear) | set;
-       add_index_entry(&o->result, ce,
-                       ADD_CACHE_OK_TO_ADD | ADD_CACHE_OK_TO_REPLACE);
+       return add_index_entry(&o->result, ce,
+                              ADD_CACHE_OK_TO_ADD | ADD_CACHE_OK_TO_REPLACE);
  }
  
  static struct cache_entry *dup_entry(const struct cache_entry *ce)
diff --cc utf8.c
Simple merge