aboutsummaryrefslogtreecommitdiff
path: root/commit.c
Commit message (Collapse)AuthorAge
* Add generic commit "pretty print" function.Linus Torvalds2005-06-01
| | | | | It's really just the header printign function from diff-tree.c, and it's usable for other things too.
* commit_list_insert: return the new commit list entryLinus Torvalds2005-05-30
| | | | | This is useful for when we want to insert the next one after this new one, for example.
* commit: save the commit buffer off when parsing a commitLinus Torvalds2005-05-25
| | | | | | | | | | | | | object. A fair number of the users potentially want to look at the commit objects more closely, and if you worry about memory leaking in certain applications, you can always do a free(commit->buffer); commit->buffer = NULL; by hand after parsing them.
* Include file cleanups..Linus Torvalds2005-05-22
| | | | | | | Add <limits.h> to the include files handled by "cache.h", and remove extraneous #include directives from various .c files. The rule is that "cache.h" gets all the basic stuff, so that we'll have as few system dependencies as possible.
* [PATCH] delta checkNicolas Pitre2005-05-20
| | | | | | | | | This adds knowledge of delta objects to fsck-cache and various object parsing code. A new switch to git-fsck-cache is provided to display the maximum delta depth found in a repository. Signed-off-by: Nicolas Pitre <nico@cam.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* commit: add "lookup_commit_reference()" helper functionLinus Torvalds2005-05-18
| | | | | It's pretty much the same as "lookup_commit()", but it will take tags too, and look up the commit (if any) associated with them.
* [PATCH] don't load and decompress objects twice with parse_object()Nicolas Pitre2005-05-06
| | | | | | | | | | | | | | | | | | | | | | | | | | It turns out that parse_object() is loading and decompressing given object to free it just before calling the specific object parsing function which does mmap and decompress the same object again. This patch introduces the ability to parse specific objects directly from a memory buffer. Without this patch, running git-fsck-cache on the kernel repositorytake: real 0m13.006s user 0m11.421s sys 0m1.218s With this patch applied: real 0m8.060s user 0m7.071s sys 0m0.710s The performance increase is significant, and this is kind of a prerequisite for sane delta object support with fsck. Signed-off-by: Nicolas Pitre <nico@cam.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] Fix memory leaks in git-fsck-cacheSergey Vlasov2005-05-04
| | | | | | | | This patch fixes memory leaks in parse_object() and related functions; these leaks were very noticeable when running git-fsck-cache. Signed-off-by: Sergey Vlasov <vsu@altlinux.ru> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] introduce xmalloc and xreallocChristopher Li2005-04-26
| | | | | | | | Introduce xmalloc and xrealloc to die gracefully with a descriptive message when out of memory, rather than taking a SIGSEGV. Signed-off-by: Christopher Li<chrislgit@chrisli.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* Don't add references to objects we couldn't find. Linus Torvalds2005-04-24
| | | | That would SIGSEGV.
* Verify that the object type matches for tree/commit objects even before parsing.Linus Torvalds2005-04-24
| | | | The type doesn't come from the parsing, the type also has to match the usage.
* Set object type at object creation time, not object parse time.Linus Torvalds2005-04-24
| | | | Otherwise we can have objects without a type, which is not good.
* [PATCH] Allow multiple date-ordered listsDaniel Barkalow2005-04-23
| | | | | | | | | | | Make pop_most_recent_commit() return the same objects multiple times, but only if called with different bits to mark. This is necessary to make merge-base work again. Signed-Off-By: Daniel Barkalow <barkalow@iabervon.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* Don't add parents to the commit list if we have alreadyLinus Torvalds2005-04-23
| | | | | | seen them. Otherwise any merges will make the parent list explode.
* [PATCH] Add some functions for commit listsDaniel Barkalow2005-04-23
| | | | | | | | | This adds a function for inserting an item in a commit list, a function for sorting a commit list by date, and a function for progressively scanning a commit history from most recent to least recent. Signed-Off-By: Daniel Barkalow <barkalow@iabervon.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* Include <limits.h> in commit.c for ULONG_MAX. Remove old "revision.h".Linus Torvalds2005-04-21
| | | | | The old revision.h helper header isn't used any more, but I never noticed it until I started grepping for ULONG_MAX users.
* [PATCH] Implementations of parsing functionsDaniel Barkalow2005-04-18
This implements the parsing functions. Signed-Off-By: Daniel Barkalow <barkalow@iabervon.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>