summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2015-08-31Don't trat a revwalk's ITEROVER as an errorCarlos Martín Nieto
2015-08-31Merge pull request #242 from pks-t/fix-populate-clone-optionsCarlos Martín Nieto
clone: do not free clone options' payload
2015-08-18clone: improve handling of remote create callbackPatrick Steinhardt
The clone options contain fields for ae remote create callback and its payload, which can be used to override the behavior when the default remote is being created for newly cloned repositories. Currently we only accept a C function as callback, though, making it overly complicated to use it. We also unconditionally `free` the payload if its address is non-`nil`, which may cause the program to segfault when the memory is not dynamically allocated. Instead, we want callers to provide a Go function that is subsequently being called by us. To do this, we introduce an indirection such that we are able to extract the provided function and payload when being called by `git_clone` and handle the return values of the user-provided function.
2015-08-13Merge pull request #241 from pks-t/memleak-fixesCarlos Martín Nieto
Memleak fixes
2015-08-12merge: fix memory leak related to merge file optsPatrick Steinhardt
2015-08-12branch: fix memory leaks related to CStringsPatrick Steinhardt
2015-07-31Merge pull request #234 from libgit2/cmn/merge-baseCarlos Martín Nieto
Wrap MergeBases
2015-07-31Wrap MergeBasesCarlos Martín Nieto
While here, test MergeBase as well.
2015-07-29Merge pull request #233 from tuexss/typosCarlos Martín Nieto
Fixed typos/unclarities in README.md
2015-07-29Headline typoAndreas Beer
2015-07-29Typos/unclarities in readme.Andreas Beer
2015-07-28Merge pull request #231 from shurcooL/master-fix-HandleList-Track-gc-issueCarlos Martín Nieto
[master] Prevent slot int variable from being GCed.
2015-07-26Prevent slot int variable from being GCed.Dmitri Shuralyov
Before this change, there were no users of slot int variable in the Go world (just a pointer to it that ended up in C world only), so Go's garbage collector would free it and its value could not retrieved later (once a pointer to it comes back to Go world from C world). Keep a pointer to it in the Go world so that does not happen. Fixes #218.
2015-07-01Adjust styleCarlos Martín Nieto
2015-07-01Merge commit 'refs/pull/198/head' of github.com:libgit2/git2goCarlos Martín Nieto
2015-07-01Merge commit 'refs/pull/174/head' of github.com:libgit2/git2goCarlos Martín Nieto
2015-06-30Merge pull request #216 from libgit2/diffCarlos Martín Nieto
Add blob diffing
2015-06-29Add DiffBlobsCarlos Martín Nieto
This lets you diff two arbitrary blobs with arbitrary names.
2015-06-29diff: remove unnecessary args to Hunk and Line ctorsCarlos Martín Nieto
2015-06-23Merge pull request #212 from libgit2/remote-handleCarlos Martín Nieto
Make the network code use handles
2015-06-10Make the network code use handlesCarlos Martín Nieto
This wasn't ported together with the rest, but it does exhibit the same issues, so let's port it over now.
2015-06-09Merge pull request #211 from shinningstar/masterCarlos Martín Nieto
Free reference resource allocated by libgit2 during go garbage collecting
2015-06-08Free reference resource allocated by libgit2 during go garbage collectingshinningstar
2015-06-08Merge pull request #210 from michaeledgar/masterCarlos Martín Nieto
Add error code matching GIT_EAUTH for authentication failures
2015-06-07Add error code matching GIT_EAUTH for authentication failuresMike Edgar
2015-05-30Fix test error messagestaylorchu
2015-05-30Merge pull request #196 from pks-t/pointer-indirectionCarlos Martín Nieto
[WIP/RFC] Pointer indirection
2015-05-22diff: only untrack notify payload when it is setPatrick Steinhardt
2015-05-22tree: use correct C callback signaturePatrick Steinhardt
2015-05-22handles: do not store handles by uintptrPatrick Steinhardt
If we store values by uintptrs the GC may try to inspect their values when it kicks in. As the pointers are most likely invalid, this will result in an invalid pointer dereference, causing the program to panic. We can fix this by storing values by an int index value instead, returning pointers to those indices as handles instead.
2015-05-22handles: panic when we cannot retrieve handle dataPatrick Steinhardt
2015-05-22packbuilder: use HandleList for C function callbacks.Patrick Steinhardt
2015-05-22blob: use HandleList for C function callbacks.Patrick Steinhardt
2015-05-22diff: use HandleList for C function callbacks.Patrick Steinhardt
2015-05-22handles: print pointer handle on panic.Patrick Steinhardt
2015-05-22odb: use HandleList for C function callbacks.Patrick Steinhardt
2015-05-22index: use HandleList for C function callbacks.Patrick Steinhardt
2015-05-22handles: start slot indices with 1Patrick Steinhardt
Using 0 as the first slot indice leads to not being able to differentiate between a handle to the first element or a NULL-handle. As current code may check whether the pointer is NULL, change the first indice to be 1 instead.
2015-05-22submodule: use HandleList for C function callbacksPatrick Steinhardt
2015-05-22tree: use HandleList for C function callbacks.Patrick Steinhardt
2015-05-22handles: correctly initialize all membersPatrick Steinhardt
2015-05-22Introduce an indirection layer for pointersCarlos Martín Nieto
As the Go runtime can move stacks at any point and the C code runs concurrently with the rest of the system, we cannot assume that the payloads we give to the C code will stay valid for any particular duration. We must therefore give the C code handles which we can then look up in our own list when the callbacks get called.
2015-05-19Merge pull request #202 from libgit2/index-basicsCarlos Martín Nieto
Add a few basic index operations
2015-05-19Index: Add Path() accessorCarlos Martín Nieto
2015-05-19Index: Add OpenIndexCarlos Martín Nieto
This lets you persist an index at an arbitrary location.
2015-05-19Index: Add ReadTree()Carlos Martín Nieto
2015-04-30Add method to check if repo is detachedFernando Oliveira
2015-04-27Merge pull request #179 from schani/masterCarlos Martín Nieto
Additions
2015-04-24Merge pull request #197 from pks-t/test-cleanupsCarlos Martín Nieto
tests: always clean up temporary repository dirs
2015-04-24tests: always clean up temporary repository dirsPatrick Steinhardt
Some test repositories are not correctly removed after the tests did run. Fix by introducing a function that is to be used for cleaning up temporary test repositories.