mirror of
https://git.proxmox.com/git/libgit2
synced 2025-08-14 11:13:52 +00:00
Merge pull request #2161 from softwarenerd/softwarenerd
Fixed missing error check on call to git_remote_download
This commit is contained in:
commit
d2b7841d66
@ -857,12 +857,15 @@ int git_remote_fetch(
|
|||||||
if ((error = git_remote_connect(remote, GIT_DIRECTION_FETCH)) != 0)
|
if ((error = git_remote_connect(remote, GIT_DIRECTION_FETCH)) != 0)
|
||||||
return error;
|
return error;
|
||||||
|
|
||||||
if ((error = git_remote_download(remote)) != 0)
|
error = git_remote_download(remote);
|
||||||
return error;
|
|
||||||
|
|
||||||
/* We don't need to be connected anymore */
|
/* We don't need to be connected anymore */
|
||||||
git_remote_disconnect(remote);
|
git_remote_disconnect(remote);
|
||||||
|
|
||||||
|
/* If the download failed, return the error */
|
||||||
|
if (error != 0)
|
||||||
|
return error;
|
||||||
|
|
||||||
/* Default reflog message */
|
/* Default reflog message */
|
||||||
if (reflog_message)
|
if (reflog_message)
|
||||||
git_buf_sets(&reflog_msg_buf, reflog_message);
|
git_buf_sets(&reflog_msg_buf, reflog_message);
|
||||||
|
Loading…
Reference in New Issue
Block a user