|
7863523a
|
2013-06-19T15:54:19
|
|
Add tests and fix use of freed memory
This adds some tests for updating the index and having it remove
items to make sure that the iteration over the index still works
even as earlier items are removed.
In testing with valgrind, this found a path that would use the
path string from the index entry after it had been freed. The
bug fix is simply to copy the path of the index entry before
doing any actual index manipulation.
|
|
f30fff45
|
2013-06-19T15:27:25
|
|
Add index pathspec-based operations
This adds three new public APIs for manipulating the index:
1. `git_index_add_all` is similar to `git add -A` and will add
files in the working directory that match a pathspec to the
index while honoring ignores, etc.
2. `git_index_remove_all` removes files from the index that match
a pathspec.
3. `git_index_update_all` updates entries in the index based on
the current contents of the working directory, either added
the new information or removing the entry from the index.
|
|
fb03a223
|
2013-06-13T16:31:11
|
|
Test has to work on case sensitive systems
|
|
1540b199
|
2013-05-31T18:12:49
|
|
some simple case-sensitive index tests
|
|
0e0108f7
|
2013-05-17T15:59:57
|
|
introduce git_conflict_iterator
|
|
96c01991
|
2013-05-15T09:24:51
|
|
Remove entry dup/free functions and fix comments
This removes the functions to duplicate and free copies of a
git_index_entry and updates the comments to explain that you
should just use the public definition of the struct as needed.
|
|
797dfb28
|
2013-05-13T16:09:33
|
|
Add APIs to dup and free git_index_entrys
This adds git_index_entry_dup to make a copy of an existing entry
and git_index_entry_free to release the memory of the copy. It
also updates the documentation for git_index_get_bypath and
git_index_get_byindex to make it clear that the returned structure
should *not* be modified.
|
|
1fed6b07
|
2013-05-13T21:57:37
|
|
Fix trailing whitespaces
|
|
75d1c8c6
|
2013-04-30T17:33:11
|
|
move NAME and REUC extensions to sys/
|
|
0462fba5
|
2013-04-30T14:56:41
|
|
renames!
|
|
1098cfae
|
2013-03-22T14:52:29
|
|
Test fixes and cleanup
This fixes some places where the new tests were leaving the test
area in a bad state or were freeing data they should not free.
It also removes code that is extraneous to the core issue and
fixes an invalid SHA being looked up in one of the tests (which
was failing, but for the wrong reason).
|
|
b8acb775
|
2013-03-07T22:15:40
|
|
Added some tests for issue #1397
Signed-off-by: Sven Strickroth <email@cs-ware.de>
|
|
1323c6d1
|
2013-03-22T14:27:56
|
|
Add cl_repo_set_bool and cleanup tests
This adds a helper function for the cases where you want to
quickly set a single boolean config value for a repository.
This allowed me to remove a lot of code.
|
|
5bddabcc
|
2013-03-04T17:40:48
|
|
clear REUC on checkout
|
|
11d9f6b3
|
2013-01-27T14:17:07
|
|
Vector improvements and their fallout
|
|
a7f8065f
|
2013-01-25T06:48:55
|
|
Use cl_assert_equal_s() instead of strcmp().
Replaced all cl_assert(!strcmp()) or semantically equivalent forms
by cl_assert_equal_s().
|
|
25743bd7
|
2013-01-12T13:47:56
|
|
add an index_remove_bypath that removes conflicts, renamed add_from_workdir to match
|
|
eb3c247a
|
2013-01-10T11:56:02
|
|
REUC needs to handle empty sides
|
|
7fc00435
|
2013-01-03T15:48:52
|
|
Add index API to remove all files in a directory
This adds the git_index_remove_directory API plus tests.
|
|
f6fded8f
|
2013-01-03T19:07:41
|
|
Proper cleanup jeez
|
|
600d8dbf
|
2013-01-03T09:10:38
|
|
Move test cleanup into cleanup functions
|
|
6fef1ab3
|
2013-01-03T07:47:51
|
|
Tests should clean up after themselves
|
|
a8122b5d
|
2012-11-21T15:39:03
|
|
Fix warnings on Win64 build
|
|
f45d51ff
|
2012-11-20T19:57:46
|
|
API updates for index.h
|
|
9094d30b
|
2012-11-23T11:41:56
|
|
Reset all static variables to NULL in clar's __cleanup
Without this change, any failed assertion in the second (or a later) test
inside a test suite has a chance of double deleting memory, resulting in
a heap corruption. See #1096 for details.
This leaves alone the test cases where we "just" use cl_git_sandbox_init()
and cl_git_sandbox_cleanup(). These methods already take good care to not
double delete a repository.
Fixes #1096
|
|
1876360f
|
2012-11-18T16:59:42
|
|
Add a test for invalid filenames while writing tree from index
|
|
d18713fb
|
2012-11-10T20:24:53
|
|
Merge pull request #1056 from nulltoken/duplicate-tree-entries
Duplicate tree entries
|
|
33f95a9b
|
2012-11-10T21:01:05
|
|
index: refine add_from_workdir() error report
|
|
69c068c7
|
2012-11-10T20:42:45
|
|
index: make git_index_new() work with a NULL path
|
|
7cc1bf0f
|
2012-11-08T21:08:59
|
|
index: Introduce git_index_has_conflicts()
|
|
43eeca04
|
2012-11-01T20:24:43
|
|
index: Fix tests
|
|
f45ec1a0
|
2012-10-29T20:04:21
|
|
index refactoring
|
|
0ae81fc4
|
2012-10-17T15:30:22
|
|
index: remove read_tree() progress indicator
git_index_read_tree() was exposing a parameter to provide the user with
a progress indicator. Unfortunately, due to the recursive nature of the
tree walk, the maximum number of items to process was unknown. Thus,
the indicator was only counting processed entries, without providing
any information how the number of remaining items.
|
|
a7dbac0b
|
2012-08-17T21:10:32
|
|
filemode: deploy enum usage
|
|
4bf51156
|
2012-07-30T14:52:46
|
|
Enable stats on git_index_read_tree.
Replace with the contents of
git_index_read_tree_with_stats() and improve
documentation comments.
|
|
da825c92
|
2012-06-19T14:27:02
|
|
Make index add/append support core.filemode flag
This fixes git_index_add and git_index_append to behave more like
core git, preserving old filemode data in the index when adding
and/or appending with core.filemode = false.
This also has placeholder support for core.symlinks and
core.ignorecase, but those flags are not implemented (well,
symlinks has partial support for preserving mode information in
the same way that git does, but it isn't tested).
|
|
3f035860
|
2012-06-07T22:43:03
|
|
misc: Fix warnings from PVS Studio trial
|
|
904b67e6
|
2012-05-18T01:48:50
|
|
errors: Rename error codes
|
|
e172cf08
|
2012-05-18T01:21:06
|
|
errors: Rename the generic return codes
|
|
946a6dc4
|
2012-05-02T16:14:30
|
|
Update test suite
|
|
13ed2966
|
2012-04-03T11:09:39
|
|
tests-clar/index: actually assert result
Signed-off-by: schu <schu-github@schulog.org>
|
|
471bb8b1
|
2012-04-03T04:52:52
|
|
tests: Cleanup & fix test suite
|
|
20ec426d
|
2012-03-31T19:47:59
|
|
Discovered cl_git_strequal! Mounted a crusade!
|
|
270303ca
|
2012-03-31T15:51:35
|
|
Moved more assertions inside Clar test helpers.
|
|
2df029ed
|
2012-03-30T06:30:32
|
|
Cleaned up build issues under Linux. Had to disable a file-mode check
in tag/write.c.
|
|
b482c420
|
2012-03-28T23:02:02
|
|
t08_tag.c ported.
Also cleaned up some names for things that used to be macros.
|
|
6c106eec
|
2012-03-28T20:09:12
|
|
t06_index.c ported.
|
|
3fd1520c
|
2012-01-24T20:35:15
|
|
Rename the Clay test suite to Clar
Clay is the name of a programming language on the makings, and we want
to avoid confusions. Sorry for the huge diff!
|