diff options
author | Ben Straub <bs@github.com> | 2013-02-05 10:59:58 -0800 |
---|---|---|
committer | Ben Straub <bs@github.com> | 2013-02-05 10:59:58 -0800 |
commit | fe95ac1b6750a29d4a132d265ec1d050f49b69e8 (patch) | |
tree | d0cf8be4771619b04ab414f8320f3a9c6600bd21 /src/clone.c | |
parent | de81aee3907e3737ad87e88e14b702f4b3bf12a6 (diff) | |
download | libgit2-fe95ac1b6750a29d4a132d265ec1d050f49b69e8.tar.gz |
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.c | 4 |
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 */ |