projects
/
git.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Make "upload-pack" match git-fetch-pack usage
[git.git]
/
receive-pack.c
diff --git
a/receive-pack.c
b/receive-pack.c
index
1768c87
..
f39703f
100644
(file)
--- a/
receive-pack.c
+++ b/
receive-pack.c
@@
-197,9
+197,7
@@
int main(int argc, char **argv)
/* chdir to the directory. If that fails, try appending ".git" */
if (chdir(dir) < 0) {
/* chdir to the directory. If that fails, try appending ".git" */
if (chdir(dir) < 0) {
- static char path[PATH_MAX];
- snprintf(path, sizeof(path), "%s.git", dir);
- if (chdir(path) < 0)
+ if (chdir(mkpath("%s.git", dir)) < 0)
die("unable to cd to %s", dir);
}
die("unable to cd to %s", dir);
}