@@ -385,7 +385,7 @@ static int fsck_obj_buffer(const struct object_id *oid, enum object_type type,
385385 * verify_packfile(), data_valid variable for details.
386386 */
387387 struct object * obj ;
388- obj = parse_object_buffer (oid -> hash , type , size , buffer , eaten );
388+ obj = parse_object_buffer (oid , type , size , buffer , eaten );
389389 if (!obj ) {
390390 errors_found |= ERROR_OBJECT ;
391391 return error ("%s: object corrupt or missing" , oid_to_hex (oid ));
@@ -444,7 +444,7 @@ static int fsck_handle_ref(const char *refname, const struct object_id *oid,
444444{
445445 struct object * obj ;
446446
447- obj = parse_object (oid -> hash );
447+ obj = parse_object (oid );
448448 if (!obj ) {
449449 error ("%s: invalid sha1 pointer %s" , refname , oid_to_hex (oid ));
450450 errors_found |= ERROR_REACHABLE ;
@@ -506,7 +506,7 @@ static struct object *parse_loose_object(const struct object_id *oid,
506506 if (!contents && type != OBJ_BLOB )
507507 die ("BUG: read_loose_object streamed a non-blob" );
508508
509- obj = parse_object_buffer (oid -> hash , type , size , contents , & eaten );
509+ obj = parse_object_buffer (oid , type , size , contents , & eaten );
510510
511511 if (!eaten )
512512 free (contents );
@@ -599,7 +599,7 @@ static int fsck_cache_tree(struct cache_tree *it)
599599 fprintf (stderr , "Checking cache tree\n" );
600600
601601 if (0 <= it -> entry_count ) {
602- struct object * obj = parse_object (it -> oid . hash );
602+ struct object * obj = parse_object (& it -> oid );
603603 if (!obj ) {
604604 error ("%s: invalid sha1 pointer in cache-tree" ,
605605 oid_to_hex (& it -> oid ));
0 commit comments