diff options
author | Stefan Beller <sbeller@google.com> | 2017-08-15 13:13:19 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2017-08-15 14:39:25 -0700 |
commit | 2456990dfd93dee6d1906d774db112056534b57b (patch) | |
tree | 77e29099725f97489df2447d834a4ce5c9c94609 /sha1_file.c | |
parent | a5b34d21521c015cd41ced4a3fdde57d79891eb3 (diff) | |
download | git-2456990dfd93dee6d1906d774db112056534b57b.tar.gz |
sha1_file: make read_info_alternates staticsb/sha1-file-cleanup
read_info_alternates is not used from outside, so let's make it static.
We have to declare the function before link_alt_odb_entry instead of
moving the code around, link_alt_odb_entry calls read_info_alternates,
which in turn calls link_alt_odb_entry.
Signed-off-by: Stefan Beller <sbeller@google.com>
Reviewed-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'sha1_file.c')
-rw-r--r-- | sha1_file.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sha1_file.c b/sha1_file.c index 7a3b745448..fac860ad9b 100644 --- a/sha1_file.c +++ b/sha1_file.c @@ -279,6 +279,7 @@ static int alt_odb_usable(struct strbuf *path, const char *normalized_objdir) * SHA1, an extra slash for the first level indirection, and the * terminating NUL. */ +static void read_info_alternates(const char * relative_base, int depth); static int link_alt_odb_entry(const char *entry, const char *relative_base, int depth, const char *normalized_objdir) { @@ -369,7 +370,7 @@ static void link_alt_odb_entries(const char *alt, int len, int sep, strbuf_release(&objdirbuf); } -void read_info_alternates(const char * relative_base, int depth) +static void read_info_alternates(const char * relative_base, int depth) { char *map; size_t mapsz; |