]> git.proxmox.com Git - libgit2.git/log
libgit2.git
8 years agoFixed typo in one of the ifndef's in pool.h used to enable/disable debug mode
Ross Delinger [Fri, 26 Feb 2016 17:51:13 +0000 (12:51 -0500)]
Fixed typo in one of the ifndef's in pool.h used to enable/disable debug mode

8 years agoRemove unnecessary ifdef in pool.h
Ross Delinger [Fri, 19 Feb 2016 14:13:40 +0000 (09:13 -0500)]
Remove unnecessary ifdef in pool.h

8 years agoAdd a new build flag to disable the pool allocator and pass all git_pool_malloc calls...
Ross Delinger [Tue, 12 Jan 2016 21:08:38 +0000 (16:08 -0500)]
Add a new build flag to disable the pool allocator and pass all git_pool_malloc calls straight to git__malloc

8 years agoMerge pull request #3562 from mgorny/ssh-read-stderr-fail
Carlos Martín Nieto [Tue, 29 Dec 2015 13:38:01 +0000 (13:38 +0000)]
Merge pull request #3562 from mgorny/ssh-read-stderr-fail

ssh_stream_read(): fix possible *bytes_read < 0 branch

8 years agoMerge pull request #3558 from libgit2/cmn/index-nolock
Carlos Martín Nieto [Mon, 28 Dec 2015 15:12:37 +0000 (15:12 +0000)]
Merge pull request #3558 from libgit2/cmn/index-nolock

index: get rid of the locking

8 years agoindex: get rid of the locking
Carlos Martín Nieto [Wed, 23 Dec 2015 11:54:52 +0000 (11:54 +0000)]
index: get rid of the locking

We don't support using an index object from multiple threads at the same
time, so the locking doesn't have any effect when following the
rules. If not following the rules, things are going to break down
anyway.

8 years agoMerge pull request #3565 from ethomson/templates
Carlos Martín Nieto [Mon, 28 Dec 2015 11:22:48 +0000 (11:22 +0000)]
Merge pull request #3565 from ethomson/templates

Handle dotfiles as the repo template dir and inside the template dir

8 years agogit_repository_init: include dotfiles when copying templates
Edward Thomson [Sun, 27 Dec 2015 04:39:22 +0000 (22:39 -0600)]
git_repository_init: include dotfiles when copying templates

Include dotfiles when copying template directory, which will handle
both a template directory itself that begins with a dotfile, and
any dotfiles inside the directory.

8 years agorepo::init tests: test a template dir with leading dot
Edward Thomson [Sun, 27 Dec 2015 04:32:17 +0000 (22:32 -0600)]
repo::init tests: test a template dir with leading dot

Ensure that we can handle template directories that begin with a
leading dot.

8 years agorepo::init tests: test init.templatedir setting
Edward Thomson [Sun, 27 Dec 2015 04:06:45 +0000 (22:06 -0600)]
repo::init tests: test init.templatedir setting

Ensure that `git_repository_init` honors the `init.templatedir`
configuration setting.

8 years agoMerge pull request #3552 from ReadmeCritic/master
Edward Thomson [Sun, 27 Dec 2015 00:31:22 +0000 (18:31 -0600)]
Merge pull request #3552 from ReadmeCritic/master

Update README URLs based on HTTP redirects

8 years agoUpdate libgit2-glib link
ReadmeCritic [Sat, 26 Dec 2015 23:51:32 +0000 (15:51 -0800)]
Update libgit2-glib link

8 years agoMerge pull request #3546 from Cruel/master
Edward Thomson [Sat, 26 Dec 2015 22:55:29 +0000 (16:55 -0600)]
Merge pull request #3546 from Cruel/master

Fix a couple function signatures

8 years agossh_stream_read(): fix possible *bytes_read < 0 branch
Michał Górny [Sat, 26 Dec 2015 16:17:05 +0000 (17:17 +0100)]
ssh_stream_read(): fix possible *bytes_read < 0 branch

Fix the possibility of returning successfully from ssh_stream_read()
with *bytes_read < 0. This would occur if stdout channel read resulted
in 0, and stderr channel read failed afterwards.

8 years agoMerge pull request #3560 from drusk/readme_typo
Edward Thomson [Thu, 24 Dec 2015 05:38:59 +0000 (23:38 -0600)]
Merge pull request #3560 from drusk/readme_typo

Fixed minor typo in README.md.

8 years agoFixed minor typo in README.md.
drusk [Thu, 24 Dec 2015 05:27:40 +0000 (21:27 -0800)]
Fixed minor typo in README.md.

8 years agoMerge pull request #3554 from olshevskiy87/master
Carlos Martín Nieto [Mon, 21 Dec 2015 21:47:10 +0000 (21:47 +0000)]
Merge pull request #3554 from olshevskiy87/master

typos in comments

8 years agotypos in comments
Dmitriy Olshevskiy [Mon, 21 Dec 2015 17:49:14 +0000 (20:49 +0300)]
typos in comments

8 years agoUpdate README URLs based on HTTP redirects
ReadmeCritic [Thu, 17 Dec 2015 16:36:04 +0000 (08:36 -0800)]
Update README URLs based on HTTP redirects

8 years agoMerge pull request #3551 from libgit2/vmg/commit-leak
Vicent Marti [Thu, 17 Dec 2015 09:29:58 +0000 (10:29 +0100)]
Merge pull request #3551 from libgit2/vmg/commit-leak

commit: Fix memory leak in test suite

8 years agocommit: Fix memory leak in test suite
Vicent Marti [Thu, 17 Dec 2015 09:13:04 +0000 (10:13 +0100)]
commit: Fix memory leak in test suite

8 years agoMerge pull request #3550 from libgit2/vmg/index-fill-2
Vicent Marti [Thu, 17 Dec 2015 09:09:02 +0000 (10:09 +0100)]
Merge pull request #3550 from libgit2/vmg/index-fill-2

Index fill: Small fixups

8 years agoMerge pull request #3548 from tepas/patch-1
Carlos Martín Nieto [Wed, 16 Dec 2015 20:58:47 +0000 (21:58 +0100)]
Merge pull request #3548 from tepas/patch-1

fix git_blob_create_fromchunks documentation

8 years agoindex: Also size-hint the hash table
Vicent Marti [Wed, 16 Dec 2015 18:36:50 +0000 (19:36 +0100)]
index: Also size-hint the hash table

Note that we're not checking whether the resize succeeds; in OOM cases,
we let it run with a "small" vector and hash table and see if by chance
we can grow it dynamically as we insert the new entries. Nothing to
lose really.

8 years agoindex: Preallocate the entries vector with size hint
Vicent Marti [Wed, 16 Dec 2015 16:00:25 +0000 (17:00 +0100)]
index: Preallocate the entries vector with size hint

8 years agoindex: Adjust namemask & mode when filling
Vicent Marti [Wed, 16 Dec 2015 15:53:06 +0000 (16:53 +0100)]
index: Adjust namemask & mode when filling

8 years agoMerge pull request #3549 from libgit2/vmg/index-fill
Carlos Martín Nieto [Wed, 16 Dec 2015 14:18:42 +0000 (15:18 +0100)]
Merge pull request #3549 from libgit2/vmg/index-fill

merge: Use `git_index__fill` to populate the index

8 years agomerge: Use `git_index__fill` to populate the index
Vicent Marti [Wed, 16 Dec 2015 11:30:52 +0000 (12:30 +0100)]
merge: Use `git_index__fill` to populate the index

Instead of calling `git_index_add` in a loop, use the new
`git_index_fill` internal API to fill the index with the initial staged
entries.

The new `fill` helper assumes that all the entries will be unique and
valid, so it can append them at the end of the entries vector and only
sort it once at the end. It performs no validation checks.

This prevents the quadratic behavior caused by having to sort the
entries list once after every insertion.

8 years agofix git_blob_create_fromchunks documentation
tepas [Tue, 15 Dec 2015 22:25:18 +0000 (09:25 +1100)]
fix git_blob_create_fromchunks documentation

putting `0.` at the start of the line turns it into a numbered list.

8 years agoFix a couple function signatures
Thomas Edvalson [Tue, 15 Dec 2015 00:21:09 +0000 (19:21 -0500)]
Fix a couple function signatures

8 years agoMerge pull request #3528 from chescock/Passthrough-from-credential-callback
Edward Thomson [Mon, 14 Dec 2015 19:54:02 +0000 (13:54 -0600)]
Merge pull request #3528 from chescock/Passthrough-from-credential-callback

Treat GIT_PASSTHROUGH as though git_cred_acquire_cb isn't set.

8 years agoMerge pull request #3521 from pks-t/blame-line-overflow
Edward Thomson [Mon, 14 Dec 2015 19:53:26 +0000 (13:53 -0600)]
Merge pull request #3521 from pks-t/blame-line-overflow

Line count overflow in git_blame_hunk and git_blame__entry

8 years agoMerge pull request #3522 from pks-t/email-format-commit-message
Carlos Martín Nieto [Thu, 10 Dec 2015 11:14:09 +0000 (12:14 +0100)]
Merge pull request #3522 from pks-t/email-format-commit-message

diff: include commit message when formatting patch

8 years agoMerge pull request #3538 from pks-t/pks/index-memory-leak
Carlos Martín Nieto [Thu, 10 Dec 2015 10:57:44 +0000 (11:57 +0100)]
Merge pull request #3538 from pks-t/pks/index-memory-leak

index: always queue `remove_entry` for removal

8 years agoMerge pull request #3542 from libgit2/cmn/reset-dir-file
Carlos Martín Nieto [Wed, 9 Dec 2015 19:56:04 +0000 (20:56 +0100)]
Merge pull request #3542 from libgit2/cmn/reset-dir-file

reset: perform the checkout before moving HEAD or the index

8 years agoreset: perform the checkout before moving HEAD or the index
Carlos Martín Nieto [Wed, 9 Dec 2015 18:16:11 +0000 (19:16 +0100)]
reset: perform the checkout before moving HEAD or the index

This keeps the state of the workdir the same as one from HEAD, removing
a source of possible confusion when calculating the work that is to be
done.

8 years agoCHANGELOG: add some things we missed
Carlos Martín Nieto [Wed, 9 Dec 2015 12:57:15 +0000 (13:57 +0100)]
CHANGELOG: add some things we missed

8 years agoMerge pull request #3539 from libgit2/typedef-submodule-cb
Carlos Martín Nieto [Tue, 8 Dec 2015 20:11:58 +0000 (21:11 +0100)]
Merge pull request #3539 from libgit2/typedef-submodule-cb

Use a typedef for the submodule_foreach callback.

8 years agoMerge pull request #3537 from libgit2/cmn/tree-is-sorted
Edward Thomson [Tue, 8 Dec 2015 18:12:27 +0000 (13:12 -0500)]
Merge pull request #3537 from libgit2/cmn/tree-is-sorted

tree: mark a tree as already sorted

8 years agoPlay nice with the docs.
joshaber [Tue, 8 Dec 2015 16:58:19 +0000 (11:58 -0500)]
Play nice with the docs.

8 years agoUse a typedef for the submodule_foreach callback.
joshaber [Tue, 8 Dec 2015 16:34:00 +0000 (11:34 -0500)]
Use a typedef for the submodule_foreach callback.

This fits with the style for the rest of the project, but more
importantly, makes life easier for bindings authors who auto-generate
code.

8 years agoindex: always queue `remove_entry` for removal
Patrick Steinhardt [Tue, 8 Dec 2015 15:00:35 +0000 (16:00 +0100)]
index: always queue `remove_entry` for removal

When replacing an index with a new one, we need to iterate
through all index entries in order to determine which entries are
equal. When it is not possible to re-use old entries for the new
index, we move it into a list of entries that are to be removed
and thus free'd.

When we encounter a non-zero error code, though, we skip adding
the current index entry to the remove-queue. `INSERT_MAP_EX`,
which is the function last run before adding to the remove-queue,
may return a positive non-zero code that indicates what exactly
happened while inserting the element. In this case we skip adding
the entry to the remove-queue but still continue the current
operation, leading to a leak of the current entry.

Fix this by checking for a negative return value instead of a
non-zero one when we want to add the current index entry to the
remove-queue.

8 years agotree: mark a tree as already sorted
Carlos Martín Nieto [Sun, 6 Dec 2015 21:51:00 +0000 (22:51 +0100)]
tree: mark a tree as already sorted

The trees are sorted on-disk, so we don't have to go over them
again. This cuts almost a fifth of time spent parsing trees.

8 years agoMerge pull request #3526 from sschuberth/cmake-number-compare
Carlos Martín Nieto [Sun, 6 Dec 2015 17:11:54 +0000 (18:11 +0100)]
Merge pull request #3526 from sschuberth/cmake-number-compare

CMakeLists: Compare CMAKE_SIZEOF_VOID_P as a number, not as a string

8 years agoMerge pull request #3529 from mgorny/fix-checkout-test-umask
Carlos Martín Nieto [Sun, 6 Dec 2015 17:11:37 +0000 (18:11 +0100)]
Merge pull request #3529 from mgorny/fix-checkout-test-umask

checkout test: Apply umask to file-mode test as well

8 years agoMerge pull request #3530 from libgit2/cmn/parse-mode
Edward Thomson [Thu, 3 Dec 2015 22:42:52 +0000 (17:42 -0500)]
Merge pull request #3530 from libgit2/cmn/parse-mode

tree: use a specialised mode parse function

8 years agoMerge pull request #3534 from ethomson/index_canonicalize_fix
Carlos Martín Nieto [Thu, 3 Dec 2015 22:37:37 +0000 (23:37 +0100)]
Merge pull request #3534 from ethomson/index_canonicalize_fix

index: canonicalize inserted paths safely

8 years agoindex: canonicalize inserted paths safely
Edward Thomson [Thu, 3 Dec 2015 21:27:15 +0000 (16:27 -0500)]
index: canonicalize inserted paths safely

When adding to the index, we look to see if a portion of the given
path matches a portion of a path in the index.  If so, we will use
the existing path information.  For example, when adding `foo/bar.c`,
if there is an index entry to `FOO/other` and the filesystem is case
insensitive, then we will put `bar.c` into the existing tree instead
of creating a new one with a different case.

Use `strncmp` to do that instead of `memcmp`.  When we `bsearch`
into the index, we locate the position where the new entry would
go.  The index entry at that position does not necessarily have
a relation to the entry we're adding, so we cannot make assumptions
and use `memcmp`.  Instead, compare them as strings.

When canonicalizing paths, we look for the first index entry that
matches a given substring.

8 years agotree: use a specialised mode parse function
Carlos Martín Nieto [Wed, 2 Dec 2015 17:56:31 +0000 (18:56 +0100)]
tree: use a specialised mode parse function

Instead of going out to strtol, which is made to parse generic numbers,
copy a parse function from git which is specialised for file modes.

8 years agoCMakeLists: Compare CMAKE_SIZEOF_VOID_P as a number, not as a string
Sebastian Schuberth [Wed, 7 Oct 2015 08:31:07 +0000 (10:31 +0200)]
CMakeLists: Compare CMAKE_SIZEOF_VOID_P as a number, not as a string

8 years agocheckout test: Apply umask to file-mode test as well
Michał Górny [Tue, 1 Dec 2015 19:41:23 +0000 (20:41 +0100)]
checkout test: Apply umask to file-mode test as well

Fix the file-mode test to expect system umask being applied to the
created file as well (it is currently applied to the directory only).
This fixes the test on systems where umask != 022.

Signed-off-by: Michał Górny <mgorny@gentoo.org>
8 years agoTreat GIT_PASSTHROUGH as though git_cred_acquire_cb isn't set.
Chris Hescock [Fri, 20 Nov 2015 16:26:26 +0000 (11:26 -0500)]
Treat GIT_PASSTHROUGH as though git_cred_acquire_cb isn't set.

8 years agoMerge pull request #3527 from pks-t/pks/tree-entry-memleak
Edward Thomson [Tue, 1 Dec 2015 13:45:55 +0000 (08:45 -0500)]
Merge pull request #3527 from pks-t/pks/tree-entry-memleak

tree: mark cloned tree entries as un-pooled

8 years agotree: mark cloned tree entries as un-pooled
Patrick Steinhardt [Tue, 1 Dec 2015 13:19:29 +0000 (14:19 +0100)]
tree: mark cloned tree entries as un-pooled

When duplicating a `struct git_tree_entry` with
`git_tree_entry_dup` the resulting structure is not allocated
inside a memory pool. As we do a 1:1 copy of the original struct,
though, we also copy the `pooled` field, which is set to `true`
for pooled entries. This results in a huge memory leak as we
never free tree entries that were duplicated from a pooled
tree entry.

Fix this by marking the newly duplicated entry as un-pooled.

9 years agodiff: include commit message when formatting patch
Patrick Steinhardt [Tue, 24 Nov 2015 12:43:43 +0000 (13:43 +0100)]
diff: include commit message when formatting patch

When formatting a patch as email we do not include the commit's
message in the formatted patch output. Implement this and add a
test that verifies behavior.

9 years agocommit: introduce `git_commit_body`
Patrick Steinhardt [Tue, 1 Dec 2015 09:03:56 +0000 (10:03 +0100)]
commit: introduce `git_commit_body`

It is already possible to get a commit's summary with the
`git_commit_summary` function. It is not possible to get the
remaining part of the commit message, that is the commit
message's body.

Fix this by introducing a new function `git_commit_body`.

9 years agoblame: use size_t for line counts in git_blame__entry
Patrick Steinhardt [Tue, 24 Nov 2015 09:52:17 +0000 (10:52 +0100)]
blame: use size_t for line counts in git_blame__entry

The `git_blame__entry` struct keeps track of line counts with
`int` fields. Since `int` is only guaranteed to be at least 16
bits we may overflow on certain platforms when line counts exceed
2^15.

Fix this by instead storing line counts in `size_t`.

9 years agoblame: use size_t for line counts in git_blame_hunk
Patrick Steinhardt [Tue, 24 Nov 2015 09:18:58 +0000 (10:18 +0100)]
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.

9 years agoMerge pull request #3508 from libgit2/cmn/tree-parse-speed
Edward Thomson [Tue, 1 Dec 2015 01:53:54 +0000 (20:53 -0500)]
Merge pull request #3508 from libgit2/cmn/tree-parse-speed

Improvements to tree parsing speed

9 years agoMerge pull request #3525 from pks-t/pks/fix-nested-struct-warning
Carlos Martín Nieto [Mon, 30 Nov 2015 19:41:54 +0000 (20:41 +0100)]
Merge pull request #3525 from pks-t/pks/fix-nested-struct-warning

Compiler warning fixes

9 years agoobject: remove unused constant OBJECT_BASE_SIZE
Patrick Steinhardt [Mon, 30 Nov 2015 17:05:27 +0000 (18:05 +0100)]
object: remove unused constant OBJECT_BASE_SIZE

9 years agotests: fix warning for nested struct initialization
Patrick Steinhardt [Mon, 30 Nov 2015 16:40:49 +0000 (17:40 +0100)]
tests: fix warning for nested struct initialization

9 years agotree: ensure the entry filename fits in 16 bits
Carlos Martín Nieto [Mon, 30 Nov 2015 16:32:18 +0000 (17:32 +0100)]
tree: ensure the entry filename fits in 16 bits

Return an error in case the length is too big. Also take this
opportunity to have a single allocating function for the size and
overflow logic.

9 years agoMerge pull request #3513 from ethomson/merge_recursive
Carlos Martín Nieto [Mon, 30 Nov 2015 03:49:31 +0000 (04:49 +0100)]
Merge pull request #3513 from ethomson/merge_recursive

Recursive Merge

9 years agotree: make path len uint16_t and avoid holes
Carlos Martín Nieto [Sat, 28 Nov 2015 18:18:29 +0000 (19:18 +0100)]
tree: make path len uint16_t and avoid holes

This reduces the size of the struct from 32 to 26 bytes, and leaves a
single padding byte at the end of the struct (which comes from the
zero-length array).

9 years agotree: calculate the filename length once
Carlos Martín Nieto [Sat, 14 Nov 2015 23:44:02 +0000 (00:44 +0100)]
tree: calculate the filename length once

We already know the size due to the `memchr()` so use that information
instead of calling `strlen()` on it.

9 years agotree: pool the entry memory allocations
Carlos Martín Nieto [Sat, 14 Nov 2015 22:50:06 +0000 (23:50 +0100)]
tree: pool the entry memory allocations

These are rather small allocations, so we end up spending a non-trivial
amount of time asking the OS for memory. Since these entries are tied to
the lifetime of their tree, we can give the tree a pool so we speed up
the allocations.

9 years agotree: avoid advancing over the filename multiple times
Carlos Martín Nieto [Sat, 14 Nov 2015 22:46:21 +0000 (23:46 +0100)]
tree: avoid advancing over the filename multiple times

We've already looked at the filename with `memchr()` and then used
`strlen()` to allocate the entry. We already know how much we have to
advance to get to the object id, so add the filename length instead of
looking at each byte again.

9 years agorecursive merge: add a recursion limit
Edward Thomson [Sat, 21 Nov 2015 00:01:42 +0000 (19:01 -0500)]
recursive merge: add a recursion limit

9 years agomerge: handle conflicts in recursive base building
Edward Thomson [Fri, 20 Nov 2015 22:33:49 +0000 (17:33 -0500)]
merge: handle conflicts in recursive base building

When building a recursive merge base, allow conflicts to occur.
Use the file (with conflict markers) as the common ancestor.

The user has already seen and dealt with this conflict by virtue
of having a criss-cross merge.  If they resolved this conflict
identically in both branches, then there will be no conflict in the
result.  This is the best case scenario.

If they did not resolve the conflict identically in the two branches,
then we will generate a new conflict.  If the user is simply using
standard conflict output then the results will be fairly sensible.
But if the user is using a mergetool or using diff3 output, then the
common ancestor will be a conflict file (itself with diff3 output,
haha!).  This is quite terrible, but it matches git's behavior.

9 years agomerge tests: add complex recursive example
Edward Thomson [Mon, 9 Nov 2015 16:55:26 +0000 (11:55 -0500)]
merge tests: add complex recursive example

9 years agorecursive: test conflict output during recursive merge
Edward Thomson [Mon, 9 Nov 2015 13:24:47 +0000 (08:24 -0500)]
recursive: test conflict output during recursive merge

9 years agomerge tests: move expected data into own file
Edward Thomson [Mon, 9 Nov 2015 13:23:27 +0000 (08:23 -0500)]
merge tests: move expected data into own file

9 years agomerge: use annotated commits for recursion
Edward Thomson [Wed, 11 Nov 2015 05:21:26 +0000 (21:21 -0800)]
merge: use annotated commits for recursion

Use annotated commits to act as our virtual bases, instead of regular
commits, to avoid polluting the odb with virtual base commits and
trees.  Instead, build an annotated commit with an index and pointers
to the commits that it was merged from.

9 years agomerge: merge annotated commits instead of regular commits
Edward Thomson [Mon, 9 Nov 2015 18:01:48 +0000 (13:01 -0500)]
merge: merge annotated commits instead of regular commits

9 years agomerge: octopus merge common ancestors when >2
Edward Thomson [Wed, 28 Oct 2015 15:00:55 +0000 (11:00 -0400)]
merge: octopus merge common ancestors when >2

When there are more than two common ancestors, continue merging the
virtual base with the additional common ancestors, effectively
octopus merging a new virtual base.

9 years agomerge: add recursive test with conflicting contents
Edward Thomson [Tue, 27 Oct 2015 23:00:30 +0000 (18:00 -0500)]
merge: add recursive test with conflicting contents

9 years agomerge: compute octopus merge bases
Edward Thomson [Tue, 27 Oct 2015 19:24:51 +0000 (14:24 -0500)]
merge: compute octopus merge bases

9 years agomerge: add recursive test with three merge bases
Edward Thomson [Tue, 27 Oct 2015 19:23:35 +0000 (14:23 -0500)]
merge: add recursive test with three merge bases

9 years agomerge: improve test names in recursive merge tests
Edward Thomson [Mon, 26 Oct 2015 21:44:36 +0000 (17:44 -0400)]
merge: improve test names in recursive merge tests

9 years agomerge: add a third-level recursive merge
Edward Thomson [Mon, 26 Oct 2015 21:25:42 +0000 (17:25 -0400)]
merge: add a third-level recursive merge

9 years agomerge: add a second-level recursive merge
Edward Thomson [Mon, 26 Oct 2015 21:14:28 +0000 (17:14 -0400)]
merge: add a second-level recursive merge

9 years agomerge: build virtual base of multiple merge bases
Edward Thomson [Mon, 26 Oct 2015 14:37:58 +0000 (10:37 -0400)]
merge: build virtual base of multiple merge bases

When the commits to merge have multiple common ancestors, build a
"virtual" base tree by merging the common ancestors.

9 years agomerge: add simple recursive test
Edward Thomson [Fri, 23 Oct 2015 00:20:07 +0000 (20:20 -0400)]
merge: add simple recursive test

Add a simple recursive test - where multiple ancestors exist and
creating a virtual merge base from them would prevent a conflict.

9 years agomerge: rename `git_merge_tree_flags_t` -> `git_merge_flags_t`
Edward Thomson [Thu, 22 Oct 2015 21:00:09 +0000 (17:00 -0400)]
merge: rename `git_merge_tree_flags_t` -> `git_merge_flags_t`

9 years agoMerge pull request #3523 from pks-t/memleak-fixes
Edward Thomson [Tue, 24 Nov 2015 19:30:41 +0000 (14:30 -0500)]
Merge pull request #3523 from pks-t/memleak-fixes

Memleak fixes

9 years agoMerge pull request #3520 from ethomson/checkout_nsecs
Carlos Martín Nieto [Tue, 24 Nov 2015 14:56:55 +0000 (15:56 +0100)]
Merge pull request #3520 from ethomson/checkout_nsecs

checkout: only consider nsecs when built that way

9 years agotests: win32::longpath: free expected_msg
Patrick Steinhardt [Tue, 24 Nov 2015 13:36:46 +0000 (14:36 +0100)]
tests: win32::longpath: free expected_msg

9 years agotests: config::stress: free `git_config` structs
Patrick Steinhardt [Tue, 24 Nov 2015 13:38:17 +0000 (14:38 +0100)]
tests: config::stress: free `git_config` structs

9 years agotests: config::global: fix memleak in open_programdata
Patrick Steinhardt [Tue, 24 Nov 2015 13:29:32 +0000 (14:29 +0100)]
tests: config::global: fix memleak in open_programdata

9 years agocheckout: only consider nsecs when built that way
Edward Thomson [Mon, 23 Nov 2015 20:49:54 +0000 (15:49 -0500)]
checkout: only consider nsecs when built that way

When examining the working directory and determining whether it's
up-to-date, only consider the nanoseconds in the index entry when
built with `GIT_USE_NSEC`.  This prevents us from believing that
the working directory is always dirty when the index was originally
written with a git client that uinderstands nsecs (like git 2.x).

9 years agoMerge pull request #3515 from jacquesg/unsigned-signed
Edward Thomson [Sat, 21 Nov 2015 16:26:18 +0000 (11:26 -0500)]
Merge pull request #3515 from jacquesg/unsigned-signed

Fix <0 unsigned comparison (stat.st_size should be an off_t)

9 years agoMake stat.st_size a __int64 not a uint64_t
Jacques Germishuys [Fri, 20 Nov 2015 18:22:38 +0000 (20:22 +0200)]
Make stat.st_size a __int64 not a uint64_t

9 years agoMerge pull request #3517 from jacquesg/warnings-fixes
Edward Thomson [Fri, 20 Nov 2015 22:57:04 +0000 (17:57 -0500)]
Merge pull request #3517 from jacquesg/warnings-fixes

Fix some warnings

9 years agoMerge pull request #3514 from jacquesg/stat-fixes
Edward Thomson [Fri, 20 Nov 2015 22:52:00 +0000 (17:52 -0500)]
Merge pull request #3514 from jacquesg/stat-fixes

Stat fixes

9 years agoMerge pull request #3516 from libgit2/cmn/repository-state-sequencer
Edward Thomson [Fri, 20 Nov 2015 20:38:33 +0000 (15:38 -0500)]
Merge pull request #3516 from libgit2/cmn/repository-state-sequencer

repository: distinguish sequencer cherry-pick and revert

9 years agoDetect stat's structure
Jacques Germishuys [Fri, 20 Nov 2015 16:57:13 +0000 (18:57 +0200)]
Detect stat's structure

9 years agoFix some warnings
Jacques Germishuys [Fri, 20 Nov 2015 18:48:51 +0000 (20:48 +0200)]
Fix some warnings

9 years agorepository: distinguish sequencer cherry-pick and revert
Carlos Martín Nieto [Fri, 20 Nov 2015 18:19:23 +0000 (13:19 -0500)]
repository: distinguish sequencer cherry-pick and revert

These are not quite like their plain counterparts and require special handling.

9 years agoMerge pull request #3511 from ethomson/racy_fixes_2
Carlos Martín Nieto [Tue, 17 Nov 2015 18:21:18 +0000 (13:21 -0500)]
Merge pull request #3511 from ethomson/racy_fixes_2

Racy fixes for writing new indexes