cache: convert struct cache_entry to use struct object_id
Convert struct cache_entry to use struct object_id by applying the following semantic patch and the object_id transforms from contrib, plus the actual change to the struct: @@ struct cache_entry E1; @@ - E1.sha1 + E1.oid.hash @@ struct cache_entry *E1; @@ - E1->sha1 + E1->oid.hash Signed-off-by: brian m. carlson <sandals@crustytoothpaste.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:

committed by
Junio C Hamano

parent
6ebdac1bab
commit
99d1a9861a
@ -168,7 +168,7 @@ static int verify_cache(struct cache_entry **cache,
|
||||
break;
|
||||
}
|
||||
fprintf(stderr, "%s: unmerged (%s)\n",
|
||||
ce->name, sha1_to_hex(ce->sha1));
|
||||
ce->name, oid_to_hex(&ce->oid));
|
||||
}
|
||||
}
|
||||
if (funny)
|
||||
@ -349,7 +349,7 @@ static int update_one(struct cache_tree *it,
|
||||
}
|
||||
}
|
||||
else {
|
||||
sha1 = ce->sha1;
|
||||
sha1 = ce->oid.hash;
|
||||
mode = ce->ce_mode;
|
||||
entlen = pathlen - baselen;
|
||||
i++;
|
||||
|
Reference in New Issue
Block a user