@@ -993,7 +993,7 @@ const char *default_notes_ref(void)
993
993
void init_notes (struct notes_tree * t , const char * notes_ref ,
994
994
combine_notes_fn combine_notes , int flags )
995
995
{
996
- unsigned char sha1 [ 20 ], object_sha1 [ 20 ] ;
996
+ struct object_id oid , object_oid ;
997
997
unsigned mode ;
998
998
struct leaf_node root_tree ;
999
999
@@ -1017,16 +1017,16 @@ void init_notes(struct notes_tree *t, const char *notes_ref,
1017
1017
t -> dirty = 0 ;
1018
1018
1019
1019
if (flags & NOTES_INIT_EMPTY || !notes_ref ||
1020
- get_sha1_treeish (notes_ref , object_sha1 ))
1020
+ get_sha1_treeish (notes_ref , object_oid . hash ))
1021
1021
return ;
1022
- if (flags & NOTES_INIT_WRITABLE && read_ref (notes_ref , object_sha1 ))
1022
+ if (flags & NOTES_INIT_WRITABLE && read_ref (notes_ref , object_oid . hash ))
1023
1023
die ("Cannot use notes ref %s" , notes_ref );
1024
- if (get_tree_entry (object_sha1 , "" , sha1 , & mode ))
1024
+ if (get_tree_entry (object_oid . hash , "" , oid . hash , & mode ))
1025
1025
die ("Failed to read notes tree referenced by %s (%s)" ,
1026
- notes_ref , sha1_to_hex ( object_sha1 ));
1026
+ notes_ref , oid_to_hex ( & object_oid ));
1027
1027
1028
1028
hashclr (root_tree .key_sha1 );
1029
- hashcpy (root_tree .val_sha1 , sha1 );
1029
+ hashcpy (root_tree .val_sha1 , oid . hash );
1030
1030
load_subtree (t , & root_tree , t -> root , 0 );
1031
1031
}
1032
1032
0 commit comments