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:
parent
2f50babef1
commit
50b6773287
@ -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;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user