summaryrefslogtreecommitdiff
path: root/src/clone.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/clone.c')
-rw-r--r--src/clone.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/clone.c b/src/clone.c
index f19771c1e..8381ec63c 100644
--- a/src/clone.c
+++ b/src/clone.c
@@ -113,11 +113,12 @@ static int update_head_to_new_branch(
const char *reflog_message)
{
git_reference *tracking_branch = NULL;
+ int error;
if (!git__prefixcmp(name, GIT_REFS_HEADS_DIR))
name += strlen(GIT_REFS_HEADS_DIR);
- int error = create_tracking_branch(&tracking_branch, repo, target, name,
+ error = create_tracking_branch(&tracking_branch, repo, target, name,
signature, reflog_message);
if (!error)