|
c8e02b87
|
2015-02-15T21:07:05
|
|
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.
|
|
a291790a
|
2015-02-15T05:18:01
|
|
Merge pull request #2831 from ethomson/merge_lock
merge: lock index during the merge (not just checkout)
|
|
a7fa970f
|
2015-02-15T05:13:50
|
|
Merge pull request #2895 from ethomson/alloc_overflow
allocations: test for overflow of requested size
|
|
41fae48d
|
2015-02-03T22:31:10
|
|
indexwriter: an indexwriter for repo operations
Provide git_indexwriter_init_for_operation for the common locking
pattern in merge, rebase, revert and cherry-pick.
|
|
8639ea5f
|
2015-01-17T22:47:03
|
|
checkout: introduce GIT_CHECKOUT_DONT_WRITE_INDEX
|
|
55798fd1
|
2015-01-17T20:49:04
|
|
git_indexwriter: lock then write the index
Introduce `git_indexwriter`, to allow us to lock the index while
performing additional operations, then complete the write (or abort,
unlocking the index).
|
|
be8404a7
|
2015-02-03T21:51:48
|
|
merge-like operations: lock index while working
|
|
8b0ddd5d
|
2015-01-17T23:28:53
|
|
merge: lock the index at the start of the merge
Always lock the index when we begin the merge, before we write
any of the metdata files. This prevents a race where another
client may run a commit after we have written the MERGE_HEAD but
before we have updated the index, which will produce a merge
commit that is treesame to one parent. The merge will finish and
update the index and the resultant commit would not be a merge at
all.
|
|
ffbd51ed
|
2015-02-13T11:38:00
|
|
rebase: `CHECKOUT_SAFE` instead of `FORCE`
Switch to a standard branch-switching pattern of a `SAFE` checkout,
then updating `HEAD`.
|
|
49b8293c
|
2015-02-13T11:20:32
|
|
rebase: allow `NULL` branch to indicate `HEAD`
Don't require the branch to rebase, if given `NULL`, simply look up
`HEAD`.
|
|
92e87dd7
|
2015-02-13T10:44:19
|
|
rebase: provide NULL `exec` on non-EXEC operations
Users may want to try to pay attention to the `exec` field on all
rebase operations.
|
|
0f07d54b
|
2015-02-13T09:35:20
|
|
pack-objects: unlock the cache on integer overflow
|
|
16942c6f
|
2015-02-12T17:36:48
|
|
integer overflow: use compiler intrinsics if supported
gcc and clang support __builtin_add_overflow, use it whenever
possible, falling back to our naive routines.
|
|
8aab36a3
|
2015-02-12T22:14:53
|
|
filebuf: use an int for return check
|
|
f1453c59
|
2015-02-12T12:19:37
|
|
Make our overflow check look more like gcc/clang's
Make our overflow checking look more like gcc and clang's, so that
we can substitute it out with the compiler instrinsics on platforms
that support it. This means dropping the ability to pass `NULL` as
an out parameter.
As a result, the macros also get updated to reflect this as well.
|
|
527ed59a
|
2015-02-13T09:18:49
|
|
win32: limit the mode to `_wopen`/`_waccess`
Win32 generally ignores Unix-like mode bits that don't make any
sense on the platform (eg `0644` makes no sense to Windows). But
WINE complains loudly when presented with POSIXy bits. Remove them.
(Thanks @phkelley)
|
|
0b2ee7c0
|
2015-02-13T08:56:01
|
|
Merge pull request #2883 from urkud/reget-reader-pointer
Reinit `reader` pointer after reading included config file
|
|
3ca91107
|
2015-02-13T08:30:21
|
|
Merge pull request #2897 from leoyanggit/fix_fileop_warning
Fix build warning on Android
|
|
650e45f6
|
2015-02-11T17:51:17
|
|
Update `khash.h` to pull request 42
https://github.com/attractivechaos/klib/pull/42/files introduces
`kreallocarray`. Hook that up as our `git__reallocarray`.
|
|
1ad48c8a
|
2015-02-11T17:36:57
|
|
khash: update to klib f28c067
|
|
190b76a6
|
2015-02-11T14:52:08
|
|
Introduce git__add_sizet_overflow and friends
Add some helper functions to check for overflow in a type-specific
manner.
|
|
8d534b47
|
2015-02-11T13:01:00
|
|
p_read: ensure requested len is ssize_t
Ensure that the given length to `p_read` is of ssize_t and ensure
that callers test the return as if it were an `ssize_t`.
|
|
ec3b4d35
|
2015-02-11T11:20:05
|
|
Use `size_t` to hold size of arrays
Use `size_t` to hold the size of arrays to ease overflow checking,
lest we check for overflow of a `size_t` then promptly truncate
by packing the length into a smaller type.
|
|
2884cc42
|
2015-02-11T09:39:38
|
|
overflow checking: don't make callers set oom
Have the ALLOC_OVERFLOW testing macros also simply set_oom in the
case where a computation would overflow, so that callers don't
need to.
|
|
4aa664ae
|
2015-02-10T23:55:07
|
|
git_buf_grow_by: increase buf asize incrementally
Introduce `git_buf_grow_by` to incrementally increase the size of a
`git_buf`, performing an overflow calculation on the growth.
|
|
3603cb09
|
2015-02-10T23:13:49
|
|
git__*allocarray: safer realloc and malloc
Introduce git__reallocarray that checks the product of the number
of elements and element size for overflow before allocation. Also
introduce git__mallocarray that behaves like calloc, but without the
`c`. (It does not zero memory, for those truly worried about every
cycle.)
|
|
392702ee
|
2015-02-09T23:41:13
|
|
allocations: test for overflow of requested size
Introduce some helper macros to test integer overflow from arithmetic
and set error message appropriately.
|
|
15d54fdd
|
2015-02-10T22:34:03
|
|
odb__hashlink: check st.st_size before casting
|
|
3556a82a
|
2015-02-09T17:35:25
|
|
Fix build warning on Android
Always do a time_t cast on st_mtime. st_mtime on Android is not
the type of time_t but has the same meaning which is the number
of seconds past epoch.
|
|
17136538
|
2015-02-05T23:39:59
|
|
Reinit `reader` pointer after reading included config file
Fixes #2869. If included file includes more files, it may reallocate
cfg_file->readers, hence invalidate not only `r` pointer, but `result`
pointer as well.
|
|
02eb1495
|
2015-02-12T15:32:52
|
|
Check rebase options version on public entry points
|
|
d24a5312
|
2015-02-12T02:34:58
|
|
Merge pull request #2866 from ethomson/checkout_perf2
Checkout performance
|
|
8e29ae73
|
2015-02-12T00:43:01
|
|
Merge pull request #2862 from jeffhostetler/jeffhostetler/bug/branch_create_after_namespace
Remove stale reflog namespace directory before branch creation
|
|
e07c1e1a
|
2015-02-12T00:40:12
|
|
Merge pull request #2880 from ethomson/mkdir_root
Ensure we can make a repo at the root of the filesystem
|
|
ec510666
|
2015-02-10T15:10:32
|
|
Credit utf8proc for utf8 iterator
|
|
cc36f424
|
2015-02-06T01:09:26
|
|
repository: parse init.templatedir as a path
This is a path so we must use the path getter so we get the tilde
expansion done.
|
|
9cb5b0f7
|
2015-02-04T23:45:22
|
|
mkdir: respect the root path
Don't try to strip trailing paths from the root directory on
Windows (trying to create `C:` will fail).
|
|
3c68bfcd
|
2015-02-04T18:24:31
|
|
stat: don't remove trailing '/' from root on win32
`p_stat` calls `git_win32_path_from_utf8`, which canonicalizes the
path. Do not further try to modify the path, else we trim the
trailing slash from a root directory and try to access `C:` instead
of `C:/`.
|
|
9bf5bd7c
|
2015-02-05T09:19:46
|
|
Merge pull request #2867 from ethomson/8dot3
Handle 8dot3 filenames being disabled on Win32
|
|
a2e4593e
|
2015-02-03T18:41:40
|
|
hash_generic: __extension__ keyword for pedantry
|
|
fa89ff20
|
2015-02-03T05:35:24
|
|
remove some unused warnings
|
|
500ec543
|
2015-02-03T01:46:01
|
|
checkout: hold seen dir paths in a map
|
|
f58cc280
|
2015-02-03T00:28:32
|
|
attr_session: keep a temp buffer
|
|
d4b1b767
|
2015-02-03T00:03:49
|
|
checkout: cache system attributes file location
|
|
710f66af
|
2015-02-03T18:41:15
|
|
bswap: remove unused bswap
|
|
5f28ec84
|
2015-02-03T12:16:11
|
|
win32: cleanup 8.3 disabled tests
|
|
1589a93a
|
2015-02-02T16:50:10
|
|
Fix branch creation when branch name matches namespace of previously deleted branch
|
|
9f779aac
|
2015-01-29T14:40:55
|
|
attrcache: don't re-read attrs during checkout
During checkout, assume that the .gitattributes files aren't
modified during the checkout. Instead, create an "attribute session"
during checkout. Assume that attribute data read in the same
checkout "session" hasn't been modified since the checkout started.
(But allow subsequent checkouts to invalidate the cache.)
Further, cache nonexistent git_attr_file data even when .gitattributes
files are not found to prevent re-scanning for nonexistent files.
|
|
9dcc4a36
|
2015-01-28T23:04:50
|
|
Fix test failures when 8.3 is disabled
|
|
1ac5acdc
|
2015-01-26T11:28:59
|
|
Merge pull request #2819 from libgit2/cmn/config-get-path
config: add parsing and getter for paths
|
|
27242199
|
2015-01-26T11:27:09
|
|
Merge pull request #2837 from swisspol/set_index
Allow passing a NULL index to git_repository_set_index()
|
|
ff80b5e8
|
2015-01-26T11:24:47
|
|
Merge pull request #2847 from jacquesg/coverity
More coverity fixes
|
|
9f1ee63d
|
2015-01-26T11:20:00
|
|
Merge pull request #2841 from swisspol/set_bare
Fixed git_repository_set_bare() not setting "core.bare" correctly
|
|
65bc22fa
|
2015-01-26T11:18:17
|
|
Merge pull request #2844 from rakuco/netinet-include-fixes
openssl: Add all required includes for AF_INET6 and in6_addr.
|
|
bb6aafe8
|
2015-01-25T14:40:23
|
|
Ensure the diff hunk callback is specified before trying to dereference it
|
|
636af219
|
2015-01-25T14:38:10
|
|
Return early if allocating a git_pathspec_match_list failed
|
|
b63b3b0e
|
2015-01-25T14:08:05
|
|
Ensure git_index_entry is not NULL before trying to free it
|
|
dc5fe00c
|
2015-01-25T00:07:23
|
|
pathspec: do not try to dereference NULL
pathspec_match_free() should not dereference a NULL passed to it.
I found this issue when I tried to run example log program with
nonexistent branch:
./example/log help
Such call leads to segmentation fault.
|
|
3cda6be7
|
2015-01-24T16:19:43
|
|
openssl: Add all required includes for AF_INET6 and in6_addr.
This fixes the build at least on FreeBSD, where those types were not
defined indirectly:
src/openssl_stream.c:100:18: error: variable has incomplete type 'struct in6_addr'
struct in6_addr addr6;
^
src/openssl_stream.c:100:9: note: forward declaration of 'struct in6_addr'
struct in6_addr addr6;
^
src/openssl_stream.c:111:18: error: use of undeclared identifier 'AF_INET'
if (p_inet_pton(AF_INET, host, &addr4)) {
^
src/unix/posix.h:31:40: note: expanded from macro 'p_inet_pton'
^
src/openssl_stream.c:115:18: error: use of undeclared identifier 'AF_INET6'
if(p_inet_pton(AF_INET6, host, &addr6)) {
^
src/unix/posix.h:31:40: note: expanded from macro 'p_inet_pton'
^
|
|
b2a7bcdb
|
2015-01-23T20:57:13
|
|
Fixed git_repository_set_bare() not setting "core.bare" correctly
|
|
fa8ca519
|
2015-01-23T15:35:29
|
|
Allow passing a NULL index to git_repository_set_index()
This is supported by the underlying set_index() implementation
and setting the repository index to NULL is recommended by the
git_repository_set_bare() documentation.
|
|
11888039
|
2015-01-23T00:18:42
|
|
checkout: free last created directory
|
|
a789b361
|
2015-01-21T09:20:54
|
|
Merge pull request #2829 from jacquesg/dead-code
Remove logically dead code (we're already asserting)
|
|
e74340b0
|
2015-01-14T18:47:00
|
|
checkout: remove files before writing new ones
On case insensitive filesystems, we may have files in the working
directory that case fold to a name we want to write. Remove those
files (by default) so that we will not end up with a filename that
has the unexpected case.
|
|
c2dee0fc
|
2015-01-14T13:20:21
|
|
checkout: drop newline in error message
|
|
b4cbd67f
|
2015-01-13T13:02:58
|
|
checkout: don't recreate previous directory
Don't bother trying to recreate the previously created directory
during checkout, for a modest reduction in the number of stats.
|
|
fe598f09
|
2015-01-13T11:18:02
|
|
mkdir: walk up tree to mkdir
Walk up the tree to mkdir, which is less immediately efficient,
but allows us to look at intermediate directories that may need
attention.
|
|
1fbfcdfc
|
2015-01-12T15:48:53
|
|
git_path_join_unrooted: return base len
The documentation for `git_path_join_unrooted` states that the base
length will be returned, so that consumers like checkout know where
to start creating directories instead of always creating directories
at the directory root.
|
|
1d50b364
|
2015-01-12T16:16:27
|
|
checkout: introduce git_checkout_perfdata
Checkout can now provide performance data about the number of (some)
syscalls performed using an optional callback.
|
|
0161e096
|
2014-11-13T19:30:47
|
|
Make binary detection work similar to vanilla git
Main change: Don't treat chars > 128 as non-printable (common in UTF-8 files)
Signed-off-by: Sven Strickroth <email@cs-ware.de>
|
|
9ae4ad2d
|
2015-01-20T23:26:55
|
|
Treat a NULL string as if it's empty
|
|
526182d2
|
2015-01-20T23:24:32
|
|
Remove logically dead code (we're already asserting)
|
|
147d86fc
|
2015-01-20T12:31:24
|
|
diff: only compute patches when requested
When we're called with no hunk or line callback, we don't need to
do the hunk or line computation.
|
|
d8b5c8c3
|
2015-01-15T15:16:19
|
|
Remove strlen() calls from loop condition
Avoid str length recalculation every iteration
|
|
eac773d9
|
2015-01-14T15:05:43
|
|
config: add parsing and getter for paths
|
|
85880693
|
2015-01-14T10:19:28
|
|
Merge branch 'pr/2740'
|
|
b3837d4d
|
2014-12-02T05:47:32
|
|
Always use GIT_HASHSIG_SMART_WHITESPACE when diffing for merges
git_merge_tree_flag_t cannot contain any GIT_DIFF_FIND_xxx flags so there's not point in checking for them
|
|
36fc5497
|
2014-12-02T05:11:12
|
|
Added GIT_HASHSIG_ALLOW_SMALL_FILES to allow computing signatures for small files
The implementation of the hashsig API disallows computing a signature on
small files containing only a few lines. This new flag disables this
behavior.
git_diff_find_similar() sets this flag by default which means that rename
/ copy detection of small files will now work. This in turn affects the
behavior of the git_status and git_blame APIs which will now detect rename
of small files assuming the right options are passed.
|
|
d4b24101
|
2015-01-09T16:47:48
|
|
Merge commit '4b1018d24f980273528743c27c47ceb96cb720bd'
Fix crash in free() when git_buf_grow() fails.
|
|
4b1018d2
|
2015-01-08T17:24:12
|
|
Fix crash in free() when git_buf_grow() fails.
|
|
a8846da7
|
2015-01-08T13:45:22
|
|
remote: plug leak
|
|
1646412d
|
2015-01-08T11:20:44
|
|
Merge pull request #2802 from calavera/remote_create_prune_config
Load prune configuration when a remote is created.
|
|
c868981f
|
2015-01-06T13:49:39
|
|
Add extern function to initialize submodule update options.
|
|
5018e2c6
|
2015-01-06T17:08:38
|
|
submodule: declare vars at top of func block
|
|
66b71ea5
|
2015-01-05T13:33:36
|
|
Fix intentation.
|
|
1ef3f0ce
|
2015-01-05T13:24:11
|
|
Load prune configuration when a remote is created.
|
|
0c601229
|
2015-01-05T20:10:43
|
|
Merge commit 'refs/pull/2632/head' of github.com:libgit2/libgit2
|
|
c070ac64
|
2015-01-01T04:14:58
|
|
Fixed internal push state not being cleared on download
git_remote_download() must also clear the internal push state resulting from a possible earlier push operation. Otherwise calling git_remote_update_tips() will execute the push version instead of the fetch version and among other things, tags won't be updated.
|
|
a3ef70bb
|
2014-12-30T11:53:55
|
|
Merge pull request #2761 from libgit2/cmn/fetch-prune
Remote-tracking branch prunning
|
|
c4c47fc2
|
2014-12-30T11:53:45
|
|
Merge pull request #2762 from libgit2/cmn/hide-push
remote: remove git_push from the public API
|
|
fe794b2e
|
2014-12-16T08:57:05
|
|
remote: remove git_push from the public API
Instead we provide git_remote_upload() and git_remote_update_tips() in
order to have a parallel API for fetching and pushing.
|
|
13da562a
|
2014-12-30T16:48:52
|
|
Merge pull request #2785 from jacquesg/coverity
Coverity fixes
|
|
dfda1cf5
|
2014-12-27T21:04:28
|
|
Check for OOM
|
|
0beb7fe4
|
2014-12-24T11:44:17
|
|
Added missing error handling path
|
|
3dbd9a0e
|
2014-12-24T11:43:38
|
|
Check the result of git_buf_joinpath
|
|
4ceb388b
|
2014-12-29T14:22:36
|
|
Merge pull request #2784 from jacquesg/undef-stat
Undef stat for Mingw
|
|
6f73e026
|
2014-12-24T11:42:50
|
|
Plug some leaks
|
|
a1daec3c
|
2014-12-29T18:11:33
|
|
Undef stat first
|
|
ddf95324
|
2014-12-29T09:30:05
|
|
Merge pull request #2783 from libgit2/cmn/treebuilder-new
treebuilder: rename _create() to _new()
|
|
7cf86f92
|
2014-12-28T10:35:26
|
|
Added AmigaOS-specific implementation of git__timer().
The clock_gettime() function is normally not available under
AmigaOS, hence another solution is required. We are using now
GetUpTime() that is present in current versions of this
operating system.
|