summaryrefslogtreecommitdiff
path: root/builtin-add.c
diff options
context:
space:
mode:
authorLiu Yubao <yubao.liu@gmail.com>2006-09-15 13:46:07 -0700
committerJunio C Hamano <junkio@cox.net>2006-09-15 13:46:07 -0700
commitd48ffdbb0b2580c6ff58da7cedbf78785ba6121b (patch)
treecaa43bd37dfd47196f1d89de4afc5918aadc9fdd /builtin-add.c
parentfc2b2be031f44aef0106cf7f872b750cd90b2253 (diff)
downloadgit-d48ffdbb0b2580c6ff58da7cedbf78785ba6121b.tar.gz
Fix duplicate xmalloc in builtin-add
[jc: patch came without sign-off but it was too obvious and trivial.] Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'builtin-add.c')
-rw-r--r--builtin-add.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/builtin-add.c b/builtin-add.c
index 0cb9c81200..febb75ed99 100644
--- a/builtin-add.c
+++ b/builtin-add.c
@@ -70,7 +70,6 @@ static void fill_directory(struct dir_struct *dir, const char **pathspec)
base = "";
if (baselen) {
char *common = xmalloc(baselen + 1);
- common = xmalloc(baselen + 1);
memcpy(common, *pathspec, baselen);
common[baselen] = 0;
path = base = common;