|
26c1cb91
|
2013-12-09T09:44:03
|
|
One more rename/cleanup for callback err functions
|
|
c7b3e1b3
|
2013-12-06T15:42:20
|
|
Some callback error check style cleanups
I find this easier to read...
|
|
25e0b157
|
2013-12-06T15:07:57
|
|
Remove converting user error to GIT_EUSER
This changes the behavior of callbacks so that the callback error
code is not converted into GIT_EUSER and instead we propagate the
return value through to the caller. Instead of using the
giterr_capture and giterr_restore functions, we now rely on all
functions to pass back the return value from a callback.
To avoid having a return value with no error message, the user
can call the public giterr_set_str or some such function to set
an error message. There is a new helper 'giterr_set_callback'
that functions can invoke after making a callback which ensures
that some error message was set in case the callback did not set
one.
In places where the sign of the callback return value is
meaningful (e.g. positive to skip, negative to abort), only the
negative values are returned back to the caller, obviously, since
the other values allow for continuing the loop.
The hardest parts of this were in the checkout code where positive
return values were overloaded as meaningful values for checkout.
I fixed this by adding an output parameter to many of the internal
checkout functions and removing the overload. This added some
code, but it is probably a better implementation.
There is some funkiness in the network code where user provided
callbacks could be returning a positive or a negative value and
we want to rely on that to cancel the loop. There are still a
couple places where an user error might get turned into GIT_EUSER
there, I think, though none exercised by the tests.
|
|
dab89f9b
|
2013-12-04T21:22:57
|
|
Further EUSER and error propagation fixes
This continues auditing all the places where GIT_EUSER is being
returned and making sure to clear any existing error using the
new giterr_user_cancel helper. As a result, places that relied
on intercepting GIT_EUSER but having the old error preserved also
needed to be cleaned up to correctly stash and then retrieve the
actual error.
Additionally, as I encountered places where error codes were not
being propagated correctly, I tried to fix them up. A number of
those fixes are included in the this commit as well.
|
|
fb190bbb
|
2013-11-12T19:44:13
|
|
Fix warnings
|
|
1e60e5f4
|
2013-11-07T12:03:44
|
|
Allow callers to set mode on packfile creation
|
|
cc2447da
|
2013-11-06T18:41:08
|
|
Add git_packbuilder_hash to query pack filename
|
|
948f00b4
|
2013-11-01T09:38:03
|
|
Merge pull request #1933 from libgit2/vmg/gcc-warnings
Warnings for Windows x64 (MSVC) and GCC on Linux
|
|
3343b5ff
|
2013-10-31T22:59:42
|
|
Fix warning on win64
|
|
ac5e507c
|
2013-11-01T09:31:52
|
|
Merge pull request #1918 from libgit2/cmn/indexer-naming
indexer: remove the stream infix
|
|
a6154f21
|
2013-10-30T15:00:05
|
|
indexer: remove the stream infix
It was there to keep it apart from the one which read in from a file on
disk. This other indexer does not exist anymore, so there is no need for
anything other than git_indexer to refer to it.
While here, rename _add() function to _append() and _finalize() to
_commit(). The former change is cosmetic, while the latter avoids
talking about "finalizing", which OO languages use to mean something
completely different.
|
|
04e0c2b2
|
2013-10-30T14:00:44
|
|
pack-objects: Depth can be negative
|
|
5c50f22a
|
2013-10-28T09:25:44
|
|
Merge pull request #1891 from libgit2/cmn/fix-thin-packs
Add support for thin packs
|
|
0b33fca0
|
2013-10-02T13:39:35
|
|
indexer: fix thin packs
When given an ODB from which to read objects, the indexer will attempt
to inject the missing bases at the end of the pack and update the
header and trailer to reflect the new contents.
|
|
51e82492
|
2013-10-03T16:54:25
|
|
pack: move the object header function here
|
|
5b188225
|
2013-10-02T13:45:32
|
|
Support cancellation in push operation
This commit adds cancellation for the push operation. This work consists of:
1) Support cancellation during push operation
- During object counting phase
- During network transfer phase
- Propagate GIT_EUSER error code out to caller
2) Improve cancellation support during fetch
- Handle cancellation request during network transfer phase
- Clear error string when cancelled during indexing
3) Fix error handling in git_smart__download_pack
Cancellation during push is still only handled in the pack building and
network transfer stages of push (and not during packbuilding).
|
|
b176eded
|
2013-09-19T14:52:57
|
|
Initial Implementation of progress reports during push
This adds the basics of progress reporting during push. While progress
for all aspects of a push operation are not reported with this change,
it lays the foundation to add these later. Push progress reporting
can be improved in the future - and consumers of the API should
just get more accurate information at that point.
The main areas where this is lacking are:
1) packbuilding progress: does not report progress during deltafication,
as this involves coordinating progress from multiple threads.
2) network progress: reports progress as objects and bytes are going
to be written to the subtransport (instead of as client gets
confirmation that they have been received by the server) and leaves
out some of the bytes that are transfered as part of the push protocol.
Basically, this reports the pack bytes that are written to the
subtransport. It does not report the bytes sent on the wire that
are received by the server. This should be a good estimate of
progress (and an improvement over no progress).
|
|
050af8bb
|
2013-07-15T16:00:00
|
|
pack: fix memory leak in error path
|
|
1a42dd17
|
2013-05-31T14:13:11
|
|
Mutex init can fail
It is obviously quite a serious problem if this happens, but mutex
initialization can fail and we should detect it. It's a bit like
a memory allocation failure, in that you're probably pretty screwed
if this occurs, but at least we'll catch it.
|
|
563c19a9
|
2013-05-11T11:36:29
|
|
packbuilder: also write index in git_packbuilder_write
git_packbuilder_write() used to write a packfile to the passed file
path. Instead, ask for a destination directory and create both the
packfile and an index, as most users probably do expect.
|
|
0b90366c
|
2013-04-23T12:27:38
|
|
Fixes indentation
|
|
f0e37a8b
|
2013-04-23T12:22:29
|
|
Added function to insert commit into pack
|
|
0e040c03
|
2013-03-03T14:50:47
|
|
indexer: use a hashtable for keeping track of offsets
These offsets are needed for REF_DELTA objects, which encode which
object they use as a base, but not where it lies in the packfile, so
we need a list.
These objects are mostly from older packfiles, before OFS_DELTA was
widely spread. The time spent in indexing these packfiles is greatly
reduced, though remains above what git is able to do.
|
|
b8b897bb
|
2013-02-11T08:28:53
|
|
Add git_push_options, to set packbuilder parallelism
|
|
f4b86126
|
2013-01-22T08:21:08
|
|
A simple perf optimization in pack-objects.c
|
|
359fc2d2
|
2013-01-08T17:07:25
|
|
update copyrights
|
|
a35b3864
|
2012-12-09T02:31:39
|
|
Always check the result of git_mutex_lock
|
|
613d5eb9
|
2012-11-28T11:42:37
|
|
Push! By schu, phkelley, and congyiwu, et al
|
|
a8122b5d
|
2012-11-21T15:39:03
|
|
Fix warnings on Win64 build
|
|
e120123e
|
2012-11-20T14:01:46
|
|
API review / update for tree.h
|
|
2508cc66
|
2012-11-18T21:38:08
|
|
Rename ref and reflog apis for consistency
|
|
aa1c3b58
|
2012-11-13T14:13:47
|
|
Merge pull request #1016 from arrbee/fix-checkout-dir-removal
Update checkout with new strategies & behavior
|
|
603bee07
|
2012-11-12T19:22:49
|
|
Remove git_hash_ctx_new - callers now _ctx_init()
|
|
d6fb0924
|
2012-11-05T12:37:15
|
|
Win32 CryptoAPI and CNG support for SHA1
|
|
757b4065
|
2012-11-09T14:01:44
|
|
Fix warnings and valgrind issues
This fixes some various warnings that showed up in Travis and
a couple uses of uninitialized memory and one memory leak.
|
|
942a7698
|
2012-11-05T06:54:34
|
|
Merge pull request #1034 from carlosmn/packbuilder-foreach
Let the user grab the packfile as it's being written
|
|
41fb1ca0
|
2012-10-29T13:41:14
|
|
Reorganize transport architecture (squashed 3)
|
|
b4b935d8
|
2012-10-31T10:43:08
|
|
packbuilder: add accessors for the number of total and written objects
|
|
3dfed9cb
|
2012-10-31T10:26:04
|
|
packbuilder: add git_packbuilder_foreach
Let the user get each object as a buffer+size pair so they can handle
the packfile content as they need to.
|
|
b4491b99
|
2012-10-16T16:18:21
|
|
Incremental improvements to pack-objects logic
Incorporate feedback for incr. improvements to pack-objects
|
|
0cf49e10
|
2012-10-09T21:49:48
|
|
fixup! gsoc-pack-objects WIP
Use khash instead of git.git's hashing algorithm.
|
|
0a32dca5
|
2012-08-19T22:26:32
|
|
gsoc-pack-objects WIP
|