From a0cd87a57044efa8aef39b476fd9240af57a1853 Mon Sep 17 00:00:00 2001 From: Martin Koegler Date: Mon, 23 Apr 2007 22:55:05 +0200 Subject: add get_sha1_with_mode get_sha1_with_mode basically behaves as get_sha1. It has an additional parameter for storing the mode of the object. If the mode can not be determined, it stores S_IFINVALID. Signed-off-by: Martin Koegler Signed-off-by: Junio C Hamano --- cache.h | 1 + 1 file changed, 1 insertion(+) (limited to 'cache.h') diff --git a/cache.h b/cache.h index b1adbe7b6e..23e8f24d5c 100644 --- a/cache.h +++ b/cache.h @@ -342,6 +342,7 @@ static inline unsigned int hexval(unsigned int c) #define DEFAULT_ABBREV 7 extern int get_sha1(const char *str, unsigned char *sha1); +extern int get_sha1_with_mode(const char *str, unsigned char *sha1, unsigned *mode); extern int get_sha1_hex(const char *hex, unsigned char *sha1); extern char *sha1_to_hex(const unsigned char *sha1); /* static buffer result! */ extern int read_ref(const char *filename, unsigned char *sha1); -- cgit v1.3