Merge branch 'jk/check-connected-with-alternates'
[gitweb.git] / sha1-file.c
index ccd5bf30bd545d2e26ef9663a4163667c4500a1e..84fd02f107602411f3ceb460e4fe5b41c212bdec 100644 (file)
@@ -1476,7 +1476,7 @@ int oid_object_info_extended(struct repository *r, const struct object_id *oid,
                /* Check if it is a missing object */
                if (fetch_if_missing && repository_format_partial_clone &&
                    !already_retried && r == the_repository &&
-                   !(flags & OBJECT_INFO_FOR_PREFETCH)) {
+                   !(flags & OBJECT_INFO_SKIP_FETCH_OBJECT)) {
                        /*
                         * TODO Investigate having fetch_object() return
                         * TODO error/success and stopping the music here.
@@ -1602,7 +1602,8 @@ void *read_object_file_extended(struct repository *r,
        return NULL;
 }
 
-void *read_object_with_reference(const struct object_id *oid,
+void *read_object_with_reference(struct repository *r,
+                                const struct object_id *oid,
                                 const char *required_type_name,
                                 unsigned long *size,
                                 struct object_id *actual_oid_return)
@@ -1618,7 +1619,7 @@ void *read_object_with_reference(const struct object_id *oid,
                int ref_length = -1;
                const char *ref_type = NULL;
 
-               buffer = read_object_file(&actual_oid, &type, &isize);
+               buffer = repo_read_object_file(r, &actual_oid, &type, &isize);
                if (!buffer)
                        return NULL;
                if (type == required_type) {