|
11bca2d2
|
2015-08-15T18:15:23
|
|
http: propagate the credentials callback's error code
When we ask for credentials, the user may choose to return EUSER to
indicate that an error has happened on its end and it wants to be given
back control.
We must therefore pass that back to the user instead of mentioning that
it was on_headers_complete() that returned an error code. Since we can,
we return the exact error code from the user (other than PASSTHROUGH)
since it doesn't cost anything, though using other error codes aren't
recommended.
|
|
755004ea
|
2015-08-14T22:12:59
|
|
Merge pull request #3362 from libgit2/cmn/curl-proxyauth-any
curl: use the most secure auth method for the proxy
|
|
9f1af7f2
|
2015-08-13T10:22:50
|
|
Merge pull request #3168 from libgit2/cmn/config-tx
Locking and transactional/atomic updates for config
|
|
5340d63d
|
2015-07-12T12:50:23
|
|
config: perform unlocking via git_transaction
This makes the API for commiting or discarding changes the same as for
references.
|
|
36f784b5
|
2015-06-01T20:02:23
|
|
config: expose locking via the main API
This lock/unlock pair allows for the cller to lock a configuration file
to avoid concurrent operations.
It also allows for a transactional approach to updating a configuration
file. If multiple updates must be made atomically, they can be done
while the config is locked.
|
|
b1667039
|
2015-06-01T19:17:03
|
|
config: implement basic transactional support
When a configuration file is locked, any updates made to it will be done
to the in-memory copy of the file. This allows for multiple updates to
happen while we hold the lock, preventing races during complex
config-file manipulation.
|
|
3ce9e4d2
|
2015-06-01T08:45:15
|
|
config: write the modified file to memory
Instead of writing into the filebuf directly, make the functions to
write the modified config file write into a buffer which can then be
dumped into the lockfile for committing.
This allows us to re-use the same code for modifying a locked
configuration, as we can simply skip the last step of dumping the data
to disk.
|
|
e3e017d4
|
2015-08-11T22:51:53
|
|
remote: don't confuse tag auto-follow rules with refspec matching
When we're looking to update a tag, we can't stop if the tag auto-follow
rules don't say to update it. The tag might still match the refspec we
were given.
|
|
dc035189
|
2015-08-06T13:02:35
|
|
curl: use the most secure auth method for the proxy
When curl uses a proxy, it will only use Basic unless we prompt it to
try to use the most secure on it has available.
This is something which git did recently, and it seems like a good idea.
|
|
eba784d2
|
2015-08-05T10:19:06
|
|
Fix duplicate basenames to support older VS
With Visual Studio versions 2008 and older they ignore the full path to files and only check
the basename of the file to find a collision. Additionally, having duplicate basenames can break
other build tools like GYP.
This fixes https://github.com/libgit2/libgit2/issues/3356
|
|
ef4857c2
|
2015-08-03T16:50:27
|
|
errors: tighten up git_error_state OOMs a bit more
When an error state is an OOM, make sure that we treat is specially
and do not try to free it.
|
|
854b701c
|
2015-08-03T15:02:02
|
|
Merge remote-tracking branches 'upstream/pr/3323' and 'upstream/pr/3329'
|
|
0fcfb60d
|
2015-07-27T10:10:18
|
|
Make giterr_restore aware of g_git_oom_error
Allow restoring a previously captured oom error, by
detecting when the captured message pointer points to the
static oom error message. This means there is no need
to strdup the message in giterr_detach.
|
|
25dbcf34
|
2015-07-27T09:59:07
|
|
Make giterr_detach no longer public
|
|
c2f17bda
|
2015-07-23T13:17:08
|
|
Ensure static oom error message not detached
Error messages that are detached are assumed to be dynamically
allocated. Passing a pointer to the static oom error message
can cause an attempt to free the static buffer later. This change
checks if the oom error message is about to be detached and detaches
a copy instead.
|
|
69adb781
|
2015-08-03T08:33:53
|
|
Merge pull request #3325 from libgit2/cmn/filebuf-rename-error
filebuf: remove lockfile upon rename errors
|
|
0dd8daea
|
2015-08-03T08:17:47
|
|
Merge pull request #3344 from libgit2/cmn/add-unreg-submodule
index: stage an unregistered submodule as well
|
|
ac728c24
|
2015-08-03T07:38:07
|
|
Handle ssh:// and git:// urls containing a '~' character.
For such a path '/~/...' the leading '/' is stripped so the server will
get a path starting with '~' and correctly handle it.
|
|
ea961abf
|
2015-08-01T19:53:53
|
|
index: stage an unregistered submodule as well
We previously added logic to `_add_bypath()` to update a submodule. Go
further and stage the submodule even if it's not registered to behave
like git.
|
|
c400bac4
|
2015-08-01T15:38:04
|
|
Merge pull request #3332 from phatblat/ben/doc-warnings
Resolve documentation warnings
|
|
c369b379
|
2015-07-31T16:23:11
|
|
Remove extra semicolon outside of a function
Without this change, compiling with gcc and pedantic generates warning:
ISO C does not allow extra ‘;’ outside of a function.
|
|
9d4b7d25
|
2015-07-29T16:46:47
|
|
Merge pull request #3328 from libgit2/cmn/iterator-skip-diriter
iterator: skip over errors in diriter init
|
|
31a76374
|
2015-07-29T22:23:00
|
|
case-insensitive check for WWW-Authenticate header
Fixes issue #3338
|
|
6d8f3a51
|
2015-07-28T08:28:33
|
|
Better param docs
|
|
f85fc367
|
2015-07-26T21:12:00
|
|
error: store the error messages in a reusable buffer
Instead of allocating a brand new buffer for each error string we want
to store, we can use a per-thread buffer to store the error string and
re-use the underlying storage. We already use the buffer to format the
string, so this mostly makes that more direct.
|
|
08afd227
|
2015-07-27T18:32:55
|
|
Fix remaining documentation warnings
|
|
12786e0f
|
2015-07-26T17:19:22
|
|
iterator: skip over errors in diriter init
An error here will typically mean that the directory was removed between
the time we iterated the parent and the time we wanted to visit it in
which case we should ignore it.
Other kinds of errors such as permissions (or transient errors) also
better dealt with by pretending we didn't see it.
|
|
19d9beb7
|
2015-07-24T19:22:41
|
|
filebuf: remove lockfile upon rename errors
When we have an error renaming the lockfile, we need to make sure
that we remove it upon cleanup. For this, we need to keep track of
whether we opened the file and whether the rename succeeded.
If we did create the lockfile but the rename did not succeed, we
remove the lockfile. This won't protect against all errors, but
the most common ones (target file is open) does get handled.
|
|
2dfd5eae
|
2015-07-24T15:05:16
|
|
Merge pull request #3307 from libgit2/cmn/submodule-backslash
Normalize submodule urls before looking at them
|
|
759b2230
|
2015-07-24T15:04:20
|
|
Merge pull request #3303 from libgit2/cmn/index-add-submodule
Allow adding a submodule through git_index_add_bypath
|
|
91dad181
|
2015-07-24T15:01:04
|
|
Merge pull request #3305 from libgit2/cmn/reflog-del-backend
refdb: delete a ref's reflog upon deletion
|
|
14e805a2
|
2015-07-24T14:59:38
|
|
Merge pull request #3304 from libgit2/cmn/checkout-free-stream
filter: make sure to close the stream even on error
|
|
4e0421fd
|
2015-07-23T10:00:55
|
|
Merge pull request #3317 from csware/fix-vista
Make libgit2 work on Windows Vista again
|
|
9830fbba
|
2015-07-22T11:33:18
|
|
Merge branch 'master' into fix-init-ordering
|
|
cf198fdf
|
2015-07-22T10:51:38
|
|
Increment `git__n_inits` before doing `init_once`.
Fixes #3318.
|
|
318bb763
|
2015-07-21T23:36:39
|
|
Make libgit2 work on Windows Vista again
(fixes issue #3316)
Signed-off-by: Sven Strickroth <email@cs-ware.de>
|
|
274f0b93
|
2015-07-15T09:17:35
|
|
Merge pull request #3311 from Fallso/MacroRedefinition
Fix macro redefinition warning
|
|
cec3569f
|
2015-07-14T15:33:56
|
|
Fix macro redefinition warning
|
|
ceb58739
|
2015-07-13T18:50:39
|
|
Merge pull request #3302 from libgit2/cmn/submodule-foreach-diff-path
List a submodule only once when the path matches a submodule in the index
|
|
a58854a0
|
2015-07-13T17:11:19
|
|
submodule, path: extract slash conversion
Extract the backslash-to-slash conversion into a helper function.
|
|
f00f005b
|
2015-07-13T09:08:32
|
|
submodule: normalize slashes in resolve_url
Our path functions expect to work with slashes, so convert a
path with backslashes into one with slashes at the top of
the function.
|
|
f861abad
|
2015-07-12T19:56:19
|
|
Merge branch 'portable-zu'
|
|
768f8be3
|
2015-06-30T19:00:41
|
|
Fix #3094 - improve use of portable size_t/ssize_t format specifiers.
The header src/cc-compat.h defines portable format specifiers PRIuZ, PRIdZ, and PRIxZ. The original report highlighted the need to use these specifiers in examples/network/fetch.c. For this commit, I checked all C source and header files not in deps/ and transitioned to the appropriate format specifier where appropriate.
|
|
01d0c02d
|
2015-07-12T19:08:06
|
|
refdb: delete a ref's reflog upon deletion
Removing a reflog upon ref deletion is something which only some
backends might wish to do. Backends which are database-backed may wish
to archive a reflog, log-based ones may not need to do anything.
|
|
4de7f3bf
|
2015-07-12T13:28:03
|
|
filter: make sure to close the stream even on error
When the stream list init or write fail, we must also make sure to close
the stream, as that's the function contract.
|
|
247d27c2
|
2015-07-11T19:41:03
|
|
index: allow add_bypath to update submodules
Similarly to how git itself does it, allow the index update operation to
stage a change in a submodule's HEAD.
|
|
0d98af09
|
2015-07-11T19:03:38
|
|
blob: fail to create a blob from a dir with EDIRECTORY
This also affects `git_index_add_bypath()` by providing a better error
message and a specific error code when a directory is passed.
|
|
08c2d3e9
|
2015-07-11T18:31:28
|
|
submodule: lookup the submodule by path if available
If we get the path from the gitmodules file, look up the submodule we're
interested in by path, rather then by name. Otherwise we might get
duplicate results.
|
|
1cd96016
|
2015-07-10T19:32:04
|
|
Merge pull request #3301 from ethomson/warnings
Clean up some warnings
|
|
a1687f78
|
2015-07-10T19:07:41
|
|
Merge pull request #3297 from tkelman/patch-2
Fix undefined reference with old versions of openssl
|
|
9c033102
|
2015-06-30T13:41:01
|
|
khash: add eol so picky compilers stop warning
|
|
a3c00cd8
|
2015-07-10T09:21:59
|
|
xdiff: cleanup some warnings
|
|
79698030
|
2015-06-29T22:51:18
|
|
git_cert: child types use proper base type
|
|
9847d80d
|
2015-07-09T18:21:31
|
|
Merge pull request #3281 from ethomson/wildcard_filters
filters: custom filters with wildcard attributes
|
|
234ca40a
|
2015-07-07T16:46:48
|
|
xdiff: upgrade to core git 2.4.5
Upgrade xdiff to version used in core git 2.4.5 (0df0541).
Corrects an issue where an LF is added at EOF while applying
an unrelated change (ba31180), cleans up some unused code (be89977 and
e5b0662), and provides an improved callback to avoid leaking internal
(to xdiff) structures (467d348).
This also adds some additional functionality that we do not yet take
advantage of, namely the ability to ignore changes whose lines are
all blank (36617af).
|
|
febc8c46
|
2015-07-07T06:55:05
|
|
Fix undefined reference with old versions of openssl
Versions prior to 0.9.8f did not have this function, rhel/centos5 are still on a
heavily backported version of 0.9.8e and theoretically supported until March 2017
Without this ifdef, I get the following link failure:
```
CMakeFiles/libgit2_clar.dir/src/openssl_stream.c.o: In function `openssl_connect':
openssl_stream.c:(.text+0x45a): undefined reference to `SSL_set_tlsext_host_name'
collect2: error: ld returned 1 exit status
make[6]: *** [libgit2_clar] Error 1
```
|
|
3704ac35
|
2015-07-07T12:38:47
|
|
Merge pull request #3277 from git-up/git_diff_index_to_index
Added git_diff_index_to_index()
|
|
ea445e06
|
2015-07-07T00:48:17
|
|
Merge pull request #3288 from ethomson/getenv
git__getenv: utf-8 aware env reader
|
|
3c831113
|
2015-07-06T19:04:48
|
|
Merge pull request #3202 from jeffhostetler/windows_stack_trace
Stacktraces with CRTDBG memory leaks on Windows
|
|
e069c621
|
2015-07-02T09:25:48
|
|
git__getenv: utf-8 aware env reader
Introduce `git__getenv` which is a UTF-8 aware `getenv` everywhere.
Make `cl_getenv` use this to keep consistent memory handling around
return values (free everywhere, as opposed to only some platforms).
|
|
dd6b24b1
|
2015-07-02T10:36:15
|
|
iterator_walk: cast away constness for free
|
|
e0af3cb3
|
2015-07-01T21:15:06
|
|
submodule: correctly delimit the keys to use for lookup
The regex we use to look at the gitmodules file does not correctly
delimit the name of submodule which we want to look up and puts '.*'
straight after the name, maching on any submodule which has the seeked
submodule as a prefix of its name.
Add the missing '\.' in the regex so we want a full stop to exist both
before and after the submodule name.
|
|
63924435
|
2015-07-01T09:40:11
|
|
filters: custom filters with wildcard attributes
Allow custom filters with wildcard attributes, so that clients
can support some random `filter=foo` in a .gitattributes and look
up the corresponding smudge/clean commands in the configuration file.
|
|
526f91f5
|
2015-07-01T14:58:13
|
|
Fix 8.3 filename tests failure when 8.3 is disabled
|
|
9126ccac
|
2015-06-30T16:48:47
|
|
Fix #3093 - remove declaration of unused function git_fetch__download_pack
Function was added in commit 2c982daa2eec64b80c7940bfe1142295bd72edd8 on October 5, 2011,
and removed in commit 41fb1ca0ec51ad1d2a14b911aab3215e42965d1b on October 29, 2012.
Given the length of time it's gone unused, it's safe to remove now.
|
|
2f60073d
|
2015-06-30T21:40:20
|
|
Merge pull request #3273 from ethomson/warnings3
More warnings
|
|
ccef5adb
|
2015-06-30T09:30:20
|
|
Added git_diff_index_to_index()
|
|
1630981e
|
2015-06-30T09:03:23
|
|
http: fixed leak when asking for credentials again
t->cred might have been allocated the previous time and needs to be
freed before asking caller for credentials again.
|
|
0305721c
|
2015-06-30T14:23:41
|
|
winhttp: remove unused var
|
|
69c8bf7e
|
2015-06-30T14:21:29
|
|
posix compat: include sys/stat.h for mingw
|
|
49840056
|
2015-06-30T14:20:31
|
|
diff: use size_t format
|
|
3451c871
|
2015-06-30T09:29:41
|
|
Merge pull request #3271 from jeffhostetler/more_leaks
memory leak refspec.c
|
|
64e6b5b0
|
2015-06-29T17:32:22
|
|
fix memory leak in refspec.c on errors.
|
|
7bfdd1c2
|
2015-06-30T10:21:06
|
|
Merge pull request #3270 from ethomson/warnings2
Remove some warnings
|
|
e5f9df7b
|
2015-06-29T21:45:04
|
|
odb: cast to long long for printf
|
|
60655056
|
2015-06-29T21:37:07
|
|
submodule: cast enum to int for compare
|
|
3ca84ac0
|
2015-06-29T20:29:29
|
|
openssl: free hostname
|
|
149d5d8a
|
2015-06-29T15:17:58
|
|
stash: drop unused variable
|
|
ded4ccab
|
2015-06-29T15:16:22
|
|
iterator_walk: drop unused variable
|
|
827b954e
|
2015-06-28T06:56:02
|
|
Reserve aux_id 0; sort leaks by aux_id. Fix cmp.
|
|
93b42728
|
2015-06-09T14:38:30
|
|
Include stacktrace summary in memory leak output.
|
|
8b380060
|
2015-06-29T21:12:44
|
|
http: don't give up on auth on the first try
When the server rejects an authentication request, ask the caller for
the credentials again, instead of giving up on the first try.
|
|
c28a5c97
|
2015-06-29T21:10:47
|
|
submodule: remove trailing slashes from submodule paths
We allow looking up a submodule by path, but we lost the path
normalisation during the recent changes. Bring it back.
|
|
cf4030b0
|
2015-06-29T20:54:17
|
|
submodule: remove some obsolete logic
Remove some of the logic that was left-over from the time we had a cache
of submodules, plugging a leak of the submodule object in certain cases.
|
|
fa399750
|
2015-06-27T21:26:27
|
|
Merge pull request #3265 from libgit2/leaks
Plug a bunch of leaks
|
|
24fa21f3
|
2015-06-26T18:59:53
|
|
index, iterator, fetchhead: plug leaks
|
|
9568660f
|
2015-06-26T18:31:39
|
|
diff: fix leaks in diff printing
|
|
cfafeb84
|
2015-06-26T18:11:05
|
|
Merge pull request #3263 from git-up/fixes
Fixes
|
|
354268ca
|
2015-06-26T17:46:35
|
|
Merge pull request #3259 from ethomson/stash_apply_argh
Stash apply: stage new files even when not updating the index
|
|
cae2a555
|
2015-06-26T08:17:56
|
|
Fixed build failure if GIT_CURL is not defined
|
|
3d9ef2dc
|
2015-06-26T16:45:42
|
|
Revert "object: correct the expected ID size in prefix lookup"
This reverts commit 969d4b703c910a8fd045baafbcd243b4c9825316.
This was a fluke from Coverity. The length to all the APIs in the
library is supposed to be passed in as nibbles, not bytes. Passing it as
bytes would prevent us from parsing uneven-sized SHA1 strings.
Also, the rest of the library was still using nibbles (including
revparse and the odb_prefix APIs), so this change was seriously breaking
things in unexpected ways. ^^
|
|
c2e1b058
|
2015-06-05T18:26:49
|
|
Only write index if updated when passing GIT_DIFF_UPDATE_INDEX
When diffing the index with the workdir and GIT_DIFF_UPDATE_INDEX has been passed,
the previous implementation was always writing the index to disk even if it wasn't
modified.
|
|
c0280bdd
|
2015-06-25T18:55:48
|
|
Merge pull request #3255 from libgit2/cmn/rename-unspecified
Rename FALLBACK to UNSPECIFIED
|
|
b7f5cb8d
|
2015-06-20T19:33:15
|
|
stash: stage new files when unstashing them
Files that were new (staged additions) in the stash tree should
be staged when unstashing, even when not applying the index.
|
|
8960dc1e
|
2015-06-24T18:10:30
|
|
iterator: provide git_iterator_walk
Provide `git_iterator_walk` to walk each iterator in lockstep,
returning each iterator's idea of the contents of the next path.
|
|
82b1c93d
|
2015-06-20T13:44:22
|
|
stash: don't allow apply with staged changes
|
|
3b66c6a3
|
2015-06-25T15:36:53
|
|
Merge pull request #3256 from libgit2/cmn/fetch-spec-fetchhead
remote: insert refspecs with no rhs in FETCH_HEAD
|
|
87987fd1
|
2015-06-25T15:26:43
|
|
Merge pull request #3246 from libgit2/cmn/dont-grow-borrowed
Don't allow growing borrowed buffers
|
|
23aa7c90
|
2015-06-25T13:40:38
|
|
remote: insert refspecs with no rhs in FETCH_HEAD
When a refspec contains no rhs and thus won't cause an explicit update,
we skip all the logic, but that means that we don't update FETCH_HEAD
with it, which is what the implicit rhs is.
Add another bit of logic which puts those remote heads in the list of
updates so we put them into FETCH_HEAD.
|
|
c2418f46
|
2015-06-25T12:48:44
|
|
Rename FALLBACK to UNSPECIFIED
Fallback describes the mechanism, while unspecified explains what the
user is thinking.
|