summaryrefslogtreecommitdiff
path: root/builtin-clone.c
diff options
context:
space:
mode:
authorAli Gholami Rudi <ali@rudi.ir>2009-04-01 15:52:25 +0430
committerJunio C Hamano <gitster@pobox.com>2009-04-01 08:58:55 -0700
commit50b5f420fe94399e3da867a0ff0585bc5d3fe86f (patch)
treef17f95155d04e630a6fd4498f71fb2fc0176135f /builtin-clone.c
parente161acd11da05add6575a6931f4ff38a5685dd7d (diff)
downloadgit-50b5f420fe94399e3da867a0ff0585bc5d3fe86f.tar.gz
builtin-clone.c: no need to strdup for setenv
The setenv function makes a copy, itself. Signed-off-by: Ali Gholami Rudi <ali@rudi.ir> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin-clone.c')
-rw-r--r--builtin-clone.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/builtin-clone.c b/builtin-clone.c
index 736c72c236..880373f279 100644
--- a/builtin-clone.c
+++ b/builtin-clone.c
@@ -406,7 +406,7 @@ int cmd_clone(int argc, const char **argv, const char *prefix)
atexit(remove_junk);
sigchain_push_common(remove_junk_on_signal);
- setenv(CONFIG_ENVIRONMENT, xstrdup(mkpath("%s/config", git_dir)), 1);
+ setenv(CONFIG_ENVIRONMENT, mkpath("%s/config", git_dir), 1);
if (safe_create_leading_directories_const(git_dir) < 0)
die("could not create leading directories of '%s'", git_dir);