Style tweaks and changes for code review feedback

This commit is contained in:
Jameson Miller 2013-10-02 15:39:18 -04:00
parent 83db7e09e2
commit 7baa7631ea
2 changed files with 8 additions and 8 deletions

View File

@ -526,8 +526,7 @@ int git_smart__download_pack(
}
} while (1);
if ((error = writepack->commit(writepack, stats)) < 0)
goto done;
error = writepack->commit(writepack, stats);
done:
if (writepack)
@ -914,9 +913,8 @@ int git_smart__push(git_transport *transport, git_push *push)
push->transfer_progress_cb(push->pb->nr_written, push->pb->nr_objects, packbuilder_payload.last_bytes, push->transfer_progress_cb_payload);
}
if (push->status.length &&
(error = update_refs_from_report(&t->refs, &push->specs, &push->status)) < 0)
goto done;
if (push->status.length)
error = update_refs_from_report(&t->refs, &push->specs, &push->status);
done:
git_buf_free(&pktline);

View File

@ -348,6 +348,7 @@ void test_online_push__cleanup(void)
static int push_pack_progress_cb(int stage, unsigned int current, unsigned int total, void* payload)
{
int *was_called = (int *) payload;
GIT_UNUSED(stage); GIT_UNUSED(current); GIT_UNUSED(total);
*was_called = 1;
return 0;
}
@ -355,6 +356,7 @@ static int push_pack_progress_cb(int stage, unsigned int current, unsigned int t
static int push_transfer_progress_cb(unsigned int current, unsigned int total, size_t bytes, void* payload)
{
int *was_called = (int *) payload;
GIT_UNUSED(current); GIT_UNUSED(total); GIT_UNUSED(bytes);
*was_called = 1;
return 0;
}