sha1_file: teach sha1_object_info_extended more flags
Improve sha1_object_info_extended() by supporting additional flags. This allows has_sha1_file_with_flags() to be modified to use sha1_object_info_extended() in a subsequent patch. Signed-off-by: Jonathan Tan <jonathantanmy@google.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
committed by
Junio C Hamano
parent
c84a1f3ed4
commit
dfdd4afcf9
4
cache.h
4
cache.h
@ -1863,6 +1863,10 @@ struct object_info {
|
||||
#define OBJECT_INFO_LOOKUP_REPLACE 1
|
||||
/* Allow reading from a loose object file of unknown/bogus type */
|
||||
#define OBJECT_INFO_ALLOW_UNKNOWN_TYPE 2
|
||||
/* Do not check cached storage */
|
||||
#define OBJECT_INFO_SKIP_CACHED 4
|
||||
/* Do not retry packed storage after checking packed and loose storage */
|
||||
#define OBJECT_INFO_QUICK 8
|
||||
extern int sha1_object_info_extended(const unsigned char *, struct object_info *, unsigned flags);
|
||||
extern int packed_object_info(struct packed_git *pack, off_t offset, struct object_info *);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user