clone.c: don't leak memory in cmd_clone

Free the refspec.
Found by scan.coverity.com (Id: 1127806)

Signed-off-by: Stefan Beller <stefanbeller@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Stefan Beller 2014-08-10 15:57:56 +02:00 committed by Junio C Hamano
parent 2f50babef1
commit 50b6773287

View File

@ -1000,5 +1000,7 @@ int cmd_clone(int argc, const char **argv, const char *prefix)
strbuf_release(&key);
strbuf_release(&value);
junk_mode = JUNK_LEAVE_ALL;
free(refspec);
return err;
}