From 6359ca60527c89609cc3bfa9b4d41a59c940717f Mon Sep 17 00:00:00 2001 From: root Date: Tue, 23 Feb 2010 14:32:45 +0000 Subject: *** empty log message *** --- eio.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'eio.c') diff --git a/eio.c b/eio.c index 1dfc7a4..937c066 100644 --- a/eio.c +++ b/eio.c @@ -139,6 +139,11 @@ # define NAME_MAX 4096 #endif +/* used for readlink etc. */ +#ifndef PATH_MAX +# define PATH_MAX 4096 +#endif + /* buffer size for various temporary buffers */ #define EIO_BUFSIZE 65536 @@ -1610,8 +1615,8 @@ static void eio_execute (etp_worker *self, eio_req *req) case EIO_SYMLINK: req->result = symlink (req->ptr1, req->ptr2); break; case EIO_MKNOD: req->result = mknod (req->ptr1, (mode_t)req->int2, (dev_t)req->int3); break; - case EIO_READLINK: ALLOC (NAME_MAX); - req->result = readlink (req->ptr1, req->ptr2, NAME_MAX); break; + case EIO_READLINK: ALLOC (PATH_MAX); + req->result = readlink (req->ptr1, req->ptr2, PATH_MAX); break; case EIO_SYNC: req->result = 0; sync (); break; case EIO_FSYNC: req->result = fsync (req->int1); break; -- cgit v1.2.3