diff options
-rw-r--r-- | src/fetch.c | 4 | ||||
-rw-r--r-- | src/push.c | 10 | ||||
-rw-r--r-- | src/remote.c | 2 |
3 files changed, 8 insertions, 8 deletions
diff --git a/src/fetch.c b/src/fetch.c index dedbb54fa..bc5961db4 100644 --- a/src/fetch.c +++ b/src/fetch.c @@ -87,10 +87,10 @@ static int filter_wants(git_remote *remote, const git_fetch_options *opts) goto cleanup; } - if (git_repository_odb__weakptr(&odb, remote->repo) < 0) + if ((error = git_repository_odb__weakptr(&odb, remote->repo)) < 0) goto cleanup; - if (git_remote_ls((const git_remote_head ***)&heads, &heads_len, remote) < 0) + if ((error = git_remote_ls((const git_remote_head ***)&heads, &heads_len, remote)) < 0) goto cleanup; for (i = 0; i < heads_len; i++) { diff --git a/src/push.c b/src/push.c index a281dc979..9733eecf9 100644 --- a/src/push.c +++ b/src/push.c @@ -291,7 +291,7 @@ static int queue_objects(git_push *push) if (git_oid_equal(&spec->loid, &spec->roid)) continue; /* up-to-date */ - if (git_odb_read_header(&size, &type, push->repo->_odb, &spec->loid) < 0) + if ((error = git_odb_read_header(&size, &type, push->repo->_odb, &spec->loid)) < 0) goto on_error; if (type == GIT_OBJECT_TAG) { @@ -301,19 +301,19 @@ static int queue_objects(git_push *push) goto on_error; if (git_object_type(target) == GIT_OBJECT_COMMIT) { - if (git_revwalk_push(rw, git_object_id(target)) < 0) { + if ((error = git_revwalk_push(rw, git_object_id(target))) < 0) { git_object_free(target); goto on_error; } } else { - if (git_packbuilder_insert( - push->pb, git_object_id(target), NULL) < 0) { + if ((error = git_packbuilder_insert( + push->pb, git_object_id(target), NULL)) < 0) { git_object_free(target); goto on_error; } } git_object_free(target); - } else if (git_revwalk_push(rw, &spec->loid) < 0) + } else if ((error = git_revwalk_push(rw, &spec->loid)) < 0) goto on_error; if (!spec->refspec.force) { diff --git a/src/remote.c b/src/remote.c index 4bab9482d..f697e0fb8 100644 --- a/src/remote.c +++ b/src/remote.c @@ -1088,7 +1088,7 @@ int git_remote_download(git_remote *remote, const git_strarray *refspecs, const if (ls_to_vector(&refs, remote) < 0) return -1; - if ((git_vector_init(&specs, 0, NULL)) < 0) + if ((error = git_vector_init(&specs, 0, NULL)) < 0) goto on_error; remote->passed_refspecs = 0; |