libgit2/include/git2
Russell Belfer 25e0b1576d 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.
2013-12-11 10:57:49 -08:00
..
sys Fix saving remotes with several fetch/push ref specs. 2013-11-01 00:08:52 +01:00
attr.h Fixed most documentation header bugs 2013-06-24 15:33:41 +02:00
blame.h Blame: change signature to be more binding-friendly 2013-11-05 11:44:42 -08:00
blob.h Merge git_buf and git_buffer 2013-09-17 09:31:45 -07:00
branch.h Change the git_branch_iterator_new and git_branch_next definitions to use git_branch_t. 2013-11-05 20:51:07 +01:00
buffer.h Port tests from PR 1683 2013-09-17 09:31:45 -07:00
checkout.h Checkout: Don't assert if treeish is NULL 2013-11-02 03:43:34 +00:00
clone.h clone: put the callbacks struct directly in the clone options 2013-10-02 14:04:44 +02:00
commit.h Introduce git_revert to revert a single commit 2013-12-02 16:57:41 -06:00
common.h Fix typo in documentation 2013-09-22 09:38:51 +08:00
config.h Remove converting user error to GIT_EUSER 2013-12-11 10:57:49 -08:00
cred_helpers.h fixing headers with bad values for objective-c 2013-09-09 13:53:22 -04:00
diff.h Add config read fns with controlled error behavior 2013-12-11 10:57:49 -08:00
errors.h Remove converting user error to GIT_EUSER 2013-12-11 10:57:49 -08:00
filter.h Merge git_buf and git_buffer 2013-09-17 09:31:45 -07:00
graph.h graph: make the ahead-behind docs clearer 2013-03-22 20:27:59 +01:00
ignore.h update copyrights 2013-01-08 17:31:27 -06:00
index.h Convert git_index_read to have a "force" flag 2013-11-01 10:20:51 -07:00
indexer.h Allow callers to set mode on packfile creation 2013-11-07 12:04:32 -05:00
inttypes.h Unify whitespaces to tabs 2013-05-15 20:26:55 +08:00
merge.h Bare naked merge and rebase 2013-12-03 10:18:53 -05:00
message.h update copyrights 2013-01-08 17:31:27 -06:00
net.h No bitfields in public headers b/c packing is compiler-specific 2013-02-07 12:47:29 -05:00
notes.h Clean up some documentation 2013-07-23 09:40:19 +02:00
object.h Blame: minor cleanup 2013-09-25 14:40:19 -07:00
odb_backend.h Take umask into account in filebuf_commit 2013-11-04 22:32:50 -05:00
odb.h Implement git_odb_object_dup 2013-10-22 16:06:12 +02:00
oid.h Merge pull request #1820 from linquize/git_oid_streq 2013-09-01 08:40:48 -07:00
pack.h Update files that reference tests-clar 2013-11-14 14:10:32 -08:00
patch.h Create git_diff_line and extend git_diff_hunk 2013-10-21 13:42:42 -07:00
pathspec.h Rename diff objects and split patch.h 2013-10-11 14:51:54 -07:00
push.h Support cancellation in push operation 2013-10-02 15:12:44 -04:00
refdb.h Move git_reference__alloc to include/git2/sys 2013-04-21 12:52:17 -07:00
reflog.h reflog: add a convenience append function 2013-10-02 06:53:24 +02:00
refs.h Make reference lookups apply precomposeunicode 2013-10-08 16:35:57 -07:00
refspec.h Fixed most documentation header bugs 2013-06-24 15:33:41 +02:00
remote.h Merge pull request #1951 from victorgp/create-remote-plus-fetch 2013-11-14 07:21:47 -08:00
repository.h clean up state metadata more consistently 2013-12-02 16:57:41 -06:00
reset.h Unify whitespaces to tabs 2013-05-15 20:26:55 +08:00
revert.h Bare naked merge and rebase 2013-12-03 10:18:53 -05:00
revparse.h Some documentation improvements 2013-08-28 09:31:32 -07:00
revwalk.h revwalk: allow simplifying by first-parent 2013-09-09 20:31:14 +02:00
signature.h Add new git_signature_default API using config 2013-08-16 15:04:15 -07:00
stash.h Make the git_signature const in the stash API. 2013-07-09 12:52:25 +02:00
status.h Make diff and status perform soft index reload 2013-11-01 10:20:51 -07:00
stdint.h msvc: Properly handle inttypes.h/stdint.h 2011-10-05 16:21:16 -04:00
strarray.h Unify whitespaces to tabs 2013-05-15 20:26:55 +08:00
submodule.h Update submodule documentation 2013-08-05 10:53:39 -07:00
tag.h tag: Introduce git_tag_annotation_create() 2013-05-21 19:32:59 +02:00
threads.h update copyrights 2013-01-08 17:31:27 -06:00
trace.h Fix trailing whitespaces 2013-05-15 22:41:30 +02:00
transport.h transport: document ssh-agent authentication 2013-11-20 14:25:55 +01:00
tree.h tree: allow retrieval of raw attributes 2013-10-08 10:07:31 +02:00
types.h merge branch into current, updating workdir 2013-11-05 10:00:39 -05:00
version.h libgit2 0.20.0 "anmeldung" 2013-11-20 12:53:33 +01:00