Mailing List Archive

[Bug 64655] New: impossible to handle path names longer than 255 characters with Aapache on FreeBSD
https://bz.apache.org/bugzilla/show_bug.cgi?id=64655

Bug ID: 64655
Summary: impossible to handle path names longer than 255
characters with Aapache on FreeBSD
Product: Apache httpd-2
Version: 2.4.43
Hardware: PC
OS: FreeBSD
Status: NEW
Severity: normal
Priority: P2
Component: Core
Assignee: bugs@httpd.apache.org
Reporter: yerterr@yahoo.com
Target Milestone: ---

It seems that it's impossible to handle path names longer than 255 characters
with Aapache on FreeBSD.

It seems to me like it may be a compilation time bug of devel/apr1
Following code fragments seems to be key in observed behaviour
------------------------------------------------------------------------------
/* header files for PATH_MAX, _POSIX_PATH_MAX */
#if APR_HAVE_LIMITS_H
#include <limits.h&gt;
#else
#if APR_HAVE_SYS_SYSLIMITS_H
#include <sys/syslimits.h&gt;
#endif
#endif
------------------------------------------------------------------------------
and
------------------------------------------------------------------------------
#if defined(PATH_MAX)
#define APR_PATH_MAX PATH_MAX
#elif defined(_POSIX_PATH_MAX)
#define APR_PATH_MAX _POSIX_PATH_MAX
#else
#error no decision has been made on APR_PATH_MAX for your platform
#endif
------------------------------------------------------------------------------
During configure I get following messages
------------------------------------------------------------------------------
checking for limits.h... (cached) yes
(...)
checking sys/syslimits.h usability... yes
checking sys/syslimits.h presence... no
configure: WARNING: sys/syslimits.h: accepted by the compiler, rejected by the
preprocessor!
configure: WARNING: sys/syslimits.h: proceeding with the compiler's result
checking for sys/syslimits.h... yes
------------------------------------------------------------------------------
It seems like limits.h of following content is being chosen:
------------------------------------------------------------------------------
#define _POSIX_PATH_MAX 255
------------------------------------------------------------------------------
And file /usr/include/sys/syslimits.h :
------------------------------------------------------------------------------
#define PATH_MAX 1024 /* max bytes in pathname */
------------------------------------------------------------------------------
It's interesting that at least my Ubuntu has file linux/limits.h with only
following value defined for PATH_MAX
------------------------------------------------------------------------------
#define PATH_MAX 4096 /* # chars in a path name including nul */
------------------------------------------------------------------------------

--
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org