Andrew's git
/
gitweb.git
/ blobdiff
summary
|
log
|
commit
|
diff
|
tree
commit
grep
author
committer
pickaxe
?
re
Add specialized object allocator
[gitweb.git]
/
commit.c
diff --git
a/commit.c
b/commit.c
index 5914200a2fba2d618951c3210e2b407c29a62d7b..0fa1198282c794b0dc9504cf5ca1432239256a05 100644
(file)
--- a/
commit.c
+++ b/
commit.c
@@
-84,7
+84,7
@@
struct commit *lookup_commit(const unsigned char *sha1)
{
struct object *obj = lookup_object(sha1);
if (!obj) {
- struct commit *ret =
xcalloc(1, sizeof(struct commit)
);
+ struct commit *ret =
alloc_commit_node(
);
created_object(sha1, &ret->object);
ret->object.type = TYPE_COMMIT;
return ret;