[PATCH v3 21/23] transport-helper: die early on encountering deleted refs
- From
Sverre Rabbelier <srabbelier@gmail.com>
- Date
- Jul 16, 2011, 13:03 UTC
- Message-ID
- <1310821424-4750-22-git-send-email-srabbelier@gmail.com>
- In-Reply-To
- <1310821424-4750-1-git-send-email-srabbelier@gmail.com>
Remote helpers do not support deleting refs by means of the 'export' command sincethe fast-import protocol does not support it.
Check explicitly for deleted refs and die early.
Signed-off-by: Sverre Rabbelier <srabbelier@gmail.com> ---
New in this series.
transport-helper.c | 4 ++++ 1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/transport-helper.c b/transport-helper.c index 74c3122..4eab844 100644 --- a/transport-helper.c +++ b/transport-helper.c @@ -746,6 +746,10 @@ 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.7.5.1.292.g728120