X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=builtin-add.c;h=febb75ed994b5edc51afc60e2d46483fa9e273f2;hb=ce4231ffa80da1888a668cc7c33f5349800ab4a3;hp=0cb9c812006ba4826122b57b9732e895b0eed905;hpb=d7b6c3c0f54b951c85cd41c6e6571c65cf090111;p=git.git diff --git a/builtin-add.c b/builtin-add.c index 0cb9c8120..febb75ed9 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;