aboutsummaryrefslogtreecommitdiff
path: root/entry.c
diff options
context:
space:
mode:
authorJonas Fonseca <fonseca@diku.dk>2006-08-26 16:09:17 +0200
committerJunio C Hamano <junkio@cox.net>2006-08-26 17:52:58 -0700
commit095c424d08d96a5f9ee3ca53ae952e92c5cff99b (patch)
tree4aac2fb179e264d7fb48813a7bd91025d449c0b3 /entry.c
parenteb950c192a0e0dfc069e16e857cbe1ae16d8ad82 (diff)
downloadgit-095c424d08d96a5f9ee3ca53ae952e92c5cff99b.tar.gz
git-095c424d08d96a5f9ee3ca53ae952e92c5cff99b.tar.xz
Use PATH_MAX instead of MAXPATHLEN
According to sys/paramh.h it's a "BSD name" for values defined in <limits.h>. Besides PATH_MAX seems to be more commonly used. Signed-off-by: Jonas Fonseca <fonseca@diku.dk> Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'entry.c')
-rw-r--r--entry.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/entry.c b/entry.c
index 793724fd5..b2ea0efa8 100644
--- a/entry.c
+++ b/entry.c
@@ -135,7 +135,7 @@ static int write_entry(struct cache_entry *ce, char *path, struct checkout *stat
int checkout_entry(struct cache_entry *ce, struct checkout *state, char *topath)
{
- static char path[MAXPATHLEN+1];
+ static char path[PATH_MAX + 1];
struct stat st;
int len = state->base_dir_len;
@@ -172,5 +172,3 @@ int checkout_entry(struct cache_entry *ce, struct checkout *state, char *topath)
create_directories(path, state);
return write_entry(ce, path, state, 0);
}
-
-