Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/libgit2.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBen Straub <bs@github.com>2013-02-05 22:59:58 +0400
committerBen Straub <bs@github.com>2013-02-05 22:59:58 +0400
commitfe95ac1b6750a29d4a132d265ec1d050f49b69e8 (patch)
treed0cf8be4771619b04ab414f8320f3a9c6600bd21 /src/clone.c
parentde81aee3907e3737ad87e88e14b702f4b3bf12a6 (diff)
Allow progress callback to cancel fetch
This works by having the indexer watch the return code of the callback, so will only take effect on object boundaries.
Diffstat (limited to 'src/clone.c')
-rw-r--r--src/clone.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/clone.c b/src/clone.c
index 333bf2148..c7a24f40a 100644
--- a/src/clone.c
+++ b/src/clone.c
@@ -355,8 +355,8 @@ static int setup_remotes_and_fetch(
/* Connect and download everything */
if (!git_remote_connect(origin, GIT_DIRECTION_FETCH)) {
- if (!git_remote_download(origin, options->fetch_progress_cb,
- options->fetch_progress_payload)) {
+ if (!(retcode = git_remote_download(origin, options->fetch_progress_cb,
+ options->fetch_progress_payload))) {
/* Create "origin/foo" branches for all remote branches */
if (!git_remote_update_tips(origin)) {
/* Point HEAD to the requested branch */