summaryrefslogtreecommitdiff
path: root/cache.h
diff options
context:
space:
mode:
authorJonathan Tan <jonathantanmy@google.com>2017-06-22 00:40:22 (GMT)
committerJunio C Hamano <gitster@pobox.com>2017-06-26 17:28:42 (GMT)
commitdfdd4afcf97b0199f44231e726e373934da77717 (patch)
tree9f2bd74ea05128dd007e85930ebf863e337dbe5f /cache.h
parentc84a1f3ed4d5314d2acc2bdca71b0bc5088423f9 (diff)
downloadgit-dfdd4afcf97b0199f44231e726e373934da77717.zip
git-dfdd4afcf97b0199f44231e726e373934da77717.tar.gz
git-dfdd4afcf97b0199f44231e726e373934da77717.tar.bz2
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>
Diffstat (limited to 'cache.h')
-rw-r--r--cache.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/cache.h b/cache.h
index 48aea92..7cf2ca4 100644
--- a/cache.h
+++ b/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 *);