]> git.proxmox.com Git - libgit2.git/commit
Add callback to git_objects_table
authorRussell Belfer <rb@github.com>
Mon, 15 Apr 2013 07:05:44 +0000 (00:05 -0700)
committerVicent Marti <tanoku@gmail.com>
Mon, 22 Apr 2013 14:51:40 +0000 (16:51 +0200)
commit786062639f05e361da977f3f1f6286141fa12fca
tree5dc63d86657681572376ef2bced9bb2cae8e2213
parent917f60c50bce09f789aeb927b45ba3bca5a23877
Add callback to git_objects_table

This adds create and free callback to the git_objects_table so
that more of the creation and destruction of objects can be table
driven instead of using switch statements.  This also makes the
semantics of certain object creation functions consistent so that
we can make better use of function pointers.  This also fixes a
theoretical error case where an object allocation fails and we
end up storing NULL into the cache.
15 files changed:
src/blob.c
src/blob.h
src/cache.c
src/cache.h
src/commit.c
src/commit.h
src/object.c
src/odb.c
src/odb.h
src/oidmap.h
src/tag.c
src/tag.h
src/tree.c
src/tree.h
tests-clar/commit/parse.c