[PATCH v6 p2 3/9] transport-helper: trivial code shuffle
- From
Felipe Contreras <felipe.contreras@gmail.com>
- Date
- Nov 24, 2012, 03:25 UTC
- Message-ID
- <1353727520-26039-4-git-send-email-felipe.contreras@gmail.com>
- In-Reply-To
- <1353727520-26039-1-git-send-email-felipe.contreras@gmail.com>
Just shuffle the die() part to make it more explicit, and cleanup the code-style.
Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com> --- transport-helper.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/transport-helper.c b/transport-helper.c index 32ad877..0c95101 100644 --- a/transport-helper.c +++ b/transport-helper.c @@ -775,6 +775,9 @@ static int push_refs_with_export(struct transport *transport, char *private; unsigned char sha1[20]; + if (ref->deletion) + die("remote-helpers do not support ref deletion"); + if (!data->refspecs) continue; private = apply_refspecs(data->refspecs, data->refspec_nr, ref->name); @@ -784,10 +787,6 @@ static int push_refs_with_export(struct transport *transport, } free(private); - if (ref->deletion) { - die("remote-helpers do not support ref deletion"); - } - if (ref->peer_ref) string_list_append(&revlist_args, ref->peer_ref->name);
-- 1.8.0