Andrew's git
/
gitweb.git
/ blobdiff
summary
|
log
|
commit
|
diff
|
tree
commit
grep
author
committer
pickaxe
?
re
Fix memory leak in prepend_to_path (git.c).
[gitweb.git]
/
git.c
diff --git
a/git.c
b/git.c
index 1d00111819f69cb4495be582bebee95be73ab214..335f405c20b3b07af5bb2e96dd00a75eb47ff809 100644
(file)
--- a/
git.c
+++ b/
git.c
@@
-36,6
+36,8
@@
static void prepend_to_path(const char *dir, int len)
memcpy(path + len + 1, old_path, path_len - len);
setenv("PATH", path, 1);
+
+ free(path);
}
static int handle_options(const char*** argv, int* argc)