summaryrefslogtreecommitdiff
path: root/src/array.h
Commit message (Collapse)AuthorAgeFilesLines
* Address PR commentsRussell Belfer2014-02-201-1/+1
| | | | | | | * Make GIT_INLINE an internal definition so it cannot be used in public headers * Fix language in CONTRIBUTING * Make index caps API use signed instead of unsigned values
* array: Wrap `array_alloc` as a single statementVicent Marti2013-11-011-2/+2
|
* Bug fixes and cleanupsRussell Belfer2013-09-171-1/+1
| | | | | | | | | | | | | This contains a few bug fixes and some header and API cleanups. The main API change is that filters should now use GIT_PASSTHROUGH to indicate that they wish to skip processing a file instead of GIT_ENOTFOUND. The bug fixes include a possible out-of-range buffer access in the ident filter, a filter ordering problem I introduced into the custom filter tests on Windows, and a filter buf NUL termination issue that was coming up on Linux.
* revwalk: make mark_unintersting use a loopCarlos Martín Nieto2013-09-061-0/+2
| | | | | | | Using a recursive function can blow the stack when dealing with long histories. Use a loop instead to limit the call chain depth. This fixes #1223.
* Fix some warningsRussell Belfer2013-07-261-5/+6
|
* Add git_pathspec_match_diff APIRussell Belfer2013-07-101-0/+2
| | | | | | | | | | | | | | | | | | This adds an additional pathspec API that will match a pathspec against a diff object. This is convenient if you want to handle renames (so you need the whole diff and can't use the pathspec constraint built into the diff API) but still want to tell if the diff had any files that matched the pathspec. When the pathspec is matched against a diff, instead of keeping a list of filenames that matched, instead the API keeps the list of git_diff_deltas that matched and they can be retrieved via a new API git_pathspec_match_list_diff_entry. There are a couple of other minor API extensions here that were mostly for the sake of convenience and to reduce dependencies on knowing the internal data structure between files inside the library.
* Convert commit->parent_ids to git_array_tRussell Belfer2013-07-101-0/+3
| | | | | | | | | This converts the array of parent SHAs from a git_vector where each SHA has to be separately allocated to a git_array_t where all the SHAs can be kept in one block. Since the two collections have almost identical APIs, there isn't much involved in making the change. I did add an API to git_array_t so that it could be allocated at a precise initial size.
* Improvements to git_arrayRussell Belfer2013-06-121-13/+38
| | | | | | | This changes the size data to uint32_t, fixes the array growth logic to use a simple 1.5x multiplier, and uses a generic inline function for growing the array to make the git_array_alloc API feel more natural (i.e. it returns a pointer to the new item).
* fix missing file and bad prototypeRussell Belfer2013-06-101-0/+41