MAXNAMELEN vs MAXNAMLEN
From: Rich Teer (rich.teer_at_rite-group.com)
Date: 01/23/04
- Next message: Peter : "Re: Problem with malloc and memcpy"
- Previous message: Eric: "PHP date question [html image swapping based on time]"
- Next in thread: Casper H.S. Dik: "Re: MAXNAMELEN vs MAXNAMLEN"
- Reply: Casper H.S. Dik: "Re: MAXNAMELEN vs MAXNAMLEN"
- Reply: lvirden_at_yahoo.com: "Re: MAXNAMELEN vs MAXNAMLEN"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Fri, 23 Jan 2004 06:46:43 GMT
Hi all,
I have a reconcilliation type of question. <sys/param.h>
says this:
/*
* MAXPATHLEN defines the longest permissible path length,
* including the terminating null, after expanding symbolic links.
* MAXNAMELEN is the length (including the terminating null) of
* the longest permissible file (component) name.
*/
#define MAXPATHLEN 1024
#define MAXNAMELEN 256
Whereas <dirent.h> says this:
#define MAXNAMLEN 512 /* maximum filename length */
So, one header file claims that the maximum length of
a file name (i.e., pathname component) is 256 characters,
and another claims that it is 512.
Shouldn't these two values be the same? I mean, how can
a UFS file system support 512 character file names when
the system itself is restricted to 256? (Or am I missing
something here?)
TIA,
-- Rich Teer, SCNA, SCSA President, Rite Online Inc. Voice: +1 (250) 979-1638 URL: http://www.rite-online.net
- Next message: Peter : "Re: Problem with malloc and memcpy"
- Previous message: Eric: "PHP date question [html image swapping based on time]"
- Next in thread: Casper H.S. Dik: "Re: MAXNAMELEN vs MAXNAMLEN"
- Reply: Casper H.S. Dik: "Re: MAXNAMELEN vs MAXNAMLEN"
- Reply: lvirden_at_yahoo.com: "Re: MAXNAMELEN vs MAXNAMLEN"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]