🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.std.unix
Article #802

Re: FILENAME_MAX & _POSIX_PATH_MAX relationship?

#802
From: Dave Decot
Date: Wed, 10 Apr 1991 22:20
24 lines
1551 bytes
Submitted-by: decot@hpisod2.cup.hp.com (Dave Decot)

> To quote from the C standard, FILENAME_MAX:
> 
>     ... expands to an integral constant expression that is the size needed
>     for an array of char large enough to hold the longest file name
>     string that the implementation guarantees can be opened. [There's
>     a footnote saying that this doesn't mean that just any string this
>     long is a valid file name.]

They can footnote all they want; the text requires me to set FILENAME_MAX
to the size of the longest filename I *guarantee* can be opened.

The length of that filename is 8, because I *guarantee* that the file
"/dev/tty" can be opened.  Anything else, depends on what's on the system.

I wish the ANSI committee would stop insisting that the wording is entirely
perfect in all respects and that therefore any unintended reading of the
wording is stupidity on the part of the reader.

Dave


Volume-Number: Volume 23, Number 27
Technical Details
Message-ID: <128358@uunet.UU.NET>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rpi!crdgw1!uunet!uunet.UU.NET!sef
References: <128112@uunet.UU.NET>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rpi!crdgw1!uunet!uunet.UU.NET!sef
From: decot@hpisod2.cup.hp.com (Dave Decot)
Newsgroups: comp.std.unix
Subject: Re: FILENAME_MAX & _POSIX_PATH_MAX relationship?
Message-ID: <128358@uunet.UU.NET>
Date: 10 Apr 91 22:20:49 GMT
References: <128112@uunet.UU.NET>
Sender: usenet@uunet.UU.NET
Organization: Hewlett Packard, Cupertino
Lines: 24
Approved: sef@uunet.uu.net (Moderator, Sean Eric Fagan - comp.std.unix)
Nntp-Posting-Host: uunet.uu.net
X-Submissions: std-unix@uunet.uu.net
Originator: sef@uunet.UU.NET