Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
For bugs related to Red Hat Enterprise Linux 2.1 product line. For Red Hat Enterprise Linux 6 and above, please visit Red Hat JIRA https://issues.redhat.com/secure/CreateIssue!default.jspa?pid=12332745 to report new issues.

Bug 69081

Summary: pathconf, fpathconf return invalid PATH_MAX
Product: Red Hat Enterprise Linux 2.1 Reporter: Matt Wilson <msw>
Component: kernelAssignee: Larry Woodman <lwoodman>
Status: CLOSED CURRENTRELEASE QA Contact: Brian Brock <bbrock>
Severity: high Docs Contact:
Priority: high    
Version: 2.1   
Target Milestone: ---   
Target Release: ---   
Hardware: i386   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2003-06-23 17:57:20 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 66521    
Bug Blocks: 69077    

Description Matt Wilson 2002-07-17 18:57:43 UTC
pathconf, fpathconf return 4095 for PATH_MAX.  The POSIX compliant value (per
the behavior in the kernel) is 4096 (which includes the NULL at the end of the
path).

Comment 1 Jakub Jelinek 2002-07-23 22:04:49 UTC
This has to change in kernel headers first and then glibc must be rebuilt against
the new kernel headers.

Comment 2 Arjan van de Ven 2002-07-24 06:54:12 UTC
changing this changes the filesystem module abi

Comment 3 Matt Wilson 2002-07-30 21:04:52 UTC
We don't need to change the value of PATH_MAX in the kernel itself.  We just
need to make sure that the value used by userspace matches the behavior of the
kernel.

All kernel code uses "PATH_MAX + 1" for allocations and checks.  This means that
the user space PATH_MAX value, per SUS version 3, MUST be 4096.  We can't change
the kernel headers (thus the fs interface) to use PATH_MAX as 4096, because then
the kernel would ACTUALLY be using 4097 as the PATH_MAX when counting the null,
as SUSv3 does.


Comment 4 Larry Woodman 2003-06-23 17:40:17 UTC
This problem was fixed in as early AS2.1 kernel errata(e.8 I think).

Larry Woodman


Comment 5 Matt Wilson 2003-06-23 17:57:20 UTC
correct.