Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2016-10-28 00:58:48 +0300
committerJunio C Hamano <gitster@pobox.com>2016-10-28 00:58:48 +0300
commit0d9c527d5963fca098ea4964f4129511bd5d82d8 (patch)
treefdc63c9e33954d77aa5299e0fb02e1cba49a01cc /cache.h
parentf9db0c055c2f93021ee32a069e15b9e54f39f0da (diff)
parent4f03666ac69ec4799998f010d04916c12e38edf8 (diff)
Merge branch 'jk/no-looking-at-dotgit-outside-repo'
Update "git diff --no-index" codepath not to try to peek into .git/ directory that happens to be under the current directory, when we know we are operating outside any repository. * jk/no-looking-at-dotgit-outside-repo: diff: handle sha1 abbreviations outside of repository diff_aligned_abbrev: use "struct oid" diff_unique_abbrev: rename to diff_aligned_abbrev find_unique_abbrev: use 4-buffer ring test-*-cache-tree: setup git dir read info/{attributes,exclude} only when in repository
Diffstat (limited to 'cache.h')
-rw-r--r--cache.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/cache.h b/cache.h
index b7f34b4ae6..1be6526d14 100644
--- a/cache.h
+++ b/cache.h
@@ -903,8 +903,8 @@ extern char *sha1_pack_index_name(const unsigned char *sha1);
* The result will be at least `len` characters long, and will be NUL
* terminated.
*
- * The non-`_r` version returns a static buffer which will be overwritten by
- * subsequent calls.
+ * The non-`_r` version returns a static buffer which remains valid until 4
+ * more calls to find_unique_abbrev are made.
*
* The `_r` variant writes to a buffer supplied by the caller, which must be at
* least `GIT_SHA1_HEXSZ + 1` bytes. The return value is the number of bytes