compressed_size = 0;
buffer = NULL;
} else if (S_ISREG(mode) || S_ISLNK(mode)) {
- enum object_type type = sha1_object_info(oid->hash, &size);
+ enum object_type type = oid_object_info(the_repository, oid,
+ &size);
method = 0;
attr2 = S_ISLNK(mode) ? ((mode | 0777) << 16) :
if (S_ISREG(mode) && type == OBJ_BLOB && !args->convert &&
size > big_file_threshold) {
- stream = open_istream(oid->hash, &type, &size, NULL);
+ stream = open_istream(oid, &type, &size, NULL);
if (!stream)
return error("cannot stream blob %s",
oid_to_hex(oid));