aboutsummaryrefslogtreecommitdiff
path: root/cache.h
diff options
context:
space:
mode:
authorJunio C Hamano <junkio@cox.net>2006-07-17 15:04:47 -0700
committerJunio C Hamano <junkio@cox.net>2006-07-25 14:15:48 -0700
commitbb6b8e4f877e8b59b3756960e29d1955072dab56 (patch)
treeec8e3f2c7a91fd3b456ae046b92dbc5f5c1ac28a /cache.h
parent96256bba949f43548a0be0af877680eb62b156f6 (diff)
downloadgit-bb6b8e4f877e8b59b3756960e29d1955072dab56.tar.gz
git-bb6b8e4f877e8b59b3756960e29d1955072dab56.tar.xz
sha1_file.c: expose map_sha1_file() interface.
This exposes map_sha1_file() interface to mmap a loose object file, and legacy_loose_object() function, split from unpack_sha1_header(). They will be used in the next patch to reuse the deflated data from new-style loose object files when generating packs. Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'cache.h')
-rw-r--r--cache.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/cache.h b/cache.h
index eee5fc9f8..01835ef43 100644
--- a/cache.h
+++ b/cache.h
@@ -240,6 +240,8 @@ extern int move_temp_to_file(const char *tmpfile, char *filename);
extern int has_sha1_pack(const unsigned char *sha1);
extern int has_sha1_file(const unsigned char *sha1);
+extern void *map_sha1_file(const unsigned char *sha1, unsigned long *);
+extern int legacy_loose_object(unsigned char *);
extern int has_pack_file(const unsigned char *sha1);
extern int has_pack_index(const unsigned char *sha1);