aboutsummaryrefslogtreecommitdiff
path: root/remote.c
diff options
context:
space:
mode:
Diffstat (limited to 'remote.c')
-rw-r--r--remote.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/remote.c b/remote.c
index 98cbcf94c..44d681da0 100644
--- a/remote.c
+++ b/remote.c
@@ -878,8 +878,7 @@ static struct ref *try_explicit_object_name(const char *name)
struct ref *ref;
if (!*name) {
- ref = alloc_ref(20);
- strcpy(ref->name, "(delete)");
+ ref = alloc_ref_from_str("(delete)");
hashclr(ref->new_sha1);
return ref;
}