void *buf = NULL;
if (oid) {
- buf = read_object_with_reference(oid->hash, tree_type, &size,
- NULL);
+ buf = read_object_with_reference(oid, tree_type, &size, NULL);
if (!buf)
die("unable to read tree %s", oid_to_hex(oid));
}
unsigned long size;
struct object_id root;
- tree = read_object_with_reference(tree_oid->hash, tree_type, &size, root.hash);
+ tree = read_object_with_reference(tree_oid, tree_type, &size, &root);
if (!tree)
return -1;
void *tree;
struct object_id root;
unsigned long size;
- tree = read_object_with_reference(current_tree_oid.hash,
+ tree = read_object_with_reference(¤t_tree_oid,
tree_type, &size,
- root.hash);
+ &root);
if (!tree)
goto done;
*/
retval = DANGLING_SYMLINK;
- contents = read_sha1_file(current_tree_oid.hash, &type,
- &link_len);
+ contents = read_object_file(¤t_tree_oid, &type,
+ &link_len);
if (!contents)
goto done;