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>
Liu Yubao committed
Sep 15, 2006 at 13:46 UTC
0b7c5a5450951dfed9017ff4dec5682219228639
1 file changed
-1
builtin-add.c
-1
@@ -70,7 +70,6 @@ static void fill_directory(struct dir_struct *dir, const char **pathspec)
70
base = "";
71
if (baselen) {
72
char *common = xmalloc(baselen + 1);
73
- common = xmalloc(baselen + 1);
73
memcpy(common, *pathspec, baselen);
74
common[baselen] = 0;
75
path = base = common;