|
add17435
|
2019-05-24T15:24:26
|
|
cache: fix cache eviction using deallocated key
When evicting cache entries, we first retrieve the object that is
to be evicted, delete the object and then finally delete the key
from the cache. In case where the cache eviction caused us to
free the cached object, though, its key will point to invalid
memory now when trying to remove it from the cache map. On my
system, this causes us to not properly remove the key from the
map, as its memory has been overwritten already and thus the key
lookup it will fail and we cannot delete it.
Fix this by only decrementing the refcount of the evictee after
we have removed it from our cache map. Add a test that caused a
segfault previous to that change.
|
|
cb1cb24c
|
2015-11-24T10:18:58
|
|
blame: use size_t for line counts in git_blame_hunk
It is not unreasonable to have versioned files with a line count
exceeding 2^16. Upon blaming such files we fail to correctly keep
track of the lines as `git_blame_hunk` stores them in `uint16_t`
fields.
Fix this by converting the line fields of `git_blame_hunk` to
`size_t`. Add test to verify behavior.
|
|
0f65733b
|
2014-04-02T18:50:47
|
|
Clar: skip tests
|
|
ada157b2
|
2014-04-02T07:45:16
|
|
Add warning when skipping blame test
|
|
d1a09004
|
2014-04-01T21:58:48
|
|
Skip blame libgit2 test if not in libgit2 repo
One blame test replies on being run from within the libgit2
repository to leverage having a longer history to play with, but
some bundled versions of libgit2 don't have the whole libgit2
history. This just skips that test if the repository can't be
opened.
|
|
0276f0f5
|
2014-02-26T19:22:19
|
|
Reset num_parents to 1 only for merge commits
Also, correct test case to account for the boundary flag
|
|
9e3b901a
|
2014-02-24T00:09:29
|
|
Add unit test
|
|
17820381
|
2013-11-14T14:05:52
|
|
Rename tests-clar to tests
|