Andrew's git
/
gitweb.git
/ diff
summary
|
log
|
commit
| diff |
tree
commit
grep
author
committer
pickaxe
?
re
clone.c: don't leak memory in cmd_clone
author
Stefan Beller
<stefanbeller@gmail.com>
Sun, 10 Aug 2014 13:57:56 +0000
(15:57 +0200)
committer
Junio C Hamano
<gitster@pobox.com>
Sun, 10 Aug 2014 23:41:14 +0000
(16:41 -0700)
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>
builtin/clone.c
patch
|
blob
|
history
raw
|
patch
| inline |
side by side
(parent:
2f50bab
)
diff --git
a/builtin/clone.c
b/builtin/clone.c
index 545105a86fdf07873948f2bbe7d1c4f6e65b1509..9129eb799fe8e4b8538e04da6be0811030984a0d 100644
(file)
--- a/
builtin/clone.c
+++ b/
builtin/clone.c
@@
-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;
}