[Mplayer-cvslog] CVS: main mplayer.c,1.637,1.638

Dominik Mierzejewski dominik at rangers.eu.org
Sun Dec 29 15:49:02 CET 2002


On Sunday, 29 December 2002, Arpi of Ize wrote:
> Update of /cvsroot/mplayer/main
> In directory mail:/var/tmp.root/cvs-serv10517
> 
> Modified Files:
> 	mplayer.c 
> Log Message:
> PATH_MAX fixed
> bugrep by Diego

Hmmm, why don't we use system-specified limits?

$ find /usr/include/ -name "*.h" | xargs grep PATH_MAX
/usr/include/linux/limits.h:#define PATH_MAX        4096	/* # chars in a path name */
/usr/include/sys/param.h:#define MAXPATHLEN	PATH_MAX
/usr/include/bits/posix1_lim.h:#define	_POSIX_PATH_MAX		256

Even stdlib.h mentions PATH_MAX:
#if defined __USE_BSD || defined __USE_XOPEN_EXTENDED
/* Return the canonical absolute name of file NAME.  The last file name
   component need not exist, and may be a symlink to a nonexistent file.
   If RESOLVED is null, the result is malloc'd; otherwise, if the canonical
   name is PATH_MAX chars or more, returns null with `errno' set to
   ENAMETOOLONG; if the name fits in fewer than PATH_MAX chars, returns the
   name in RESOLVED.  */
extern char *realpath (__const char *__restrict __name,
                       char *__restrict __resolved) __THROW;
#endif

-- 
MPlayer RPMs maintainer: http://www.piorunek.pl/~dominik/linux/pkgs/mplayer/
"The Universe doesn't give you any points for doing things that are easy."
        -- Sheridan to Garibaldi in Babylon 5:"The Geometry of Shadows"



More information about the MPlayer-cvslog mailing list