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:
authorElijah Newren <newren@gmail.com>2020-12-13 11:04:25 +0300
committerJunio C Hamano <gitster@pobox.com>2020-12-14 01:18:20 +0300
commit70912f66de751b2f1af145887dc64c9c0d06de36 (patch)
tree43473ea1d368b1cc0122ddd0996611102bb3affc
parent6681ce5cf6a869aa73cfe56d041dce133262587a (diff)
tree: enable cmp_cache_name_compare() to be used elsewhere
Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
-rw-r--r--tree.c2
-rw-r--r--tree.h2
2 files changed, 3 insertions, 1 deletions
diff --git a/tree.c b/tree.c
index e76517f6b1..a52479812c 100644
--- a/tree.c
+++ b/tree.c
@@ -144,7 +144,7 @@ int read_tree_recursive(struct repository *r,
return ret;
}
-static int cmp_cache_name_compare(const void *a_, const void *b_)
+int cmp_cache_name_compare(const void *a_, const void *b_)
{
const struct cache_entry *ce1, *ce2;
diff --git a/tree.h b/tree.h
index 9383745073..3eb0484cbf 100644
--- a/tree.h
+++ b/tree.h
@@ -28,6 +28,8 @@ void free_tree_buffer(struct tree *tree);
/* Parses and returns the tree in the given ent, chasing tags and commits. */
struct tree *parse_tree_indirect(const struct object_id *oid);
+int cmp_cache_name_compare(const void *a_, const void *b_);
+
#define READ_TREE_RECURSIVE 1
typedef int (*read_tree_fn_t)(const struct object_id *, struct strbuf *, const char *, unsigned int, int, void *);