Re: Max string size of filePath+filenName

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi People,

>
> When a user tries to open a file using the open()
> function from user space, what is the max size of
> "path to the file" + "Name of the file".  Does the
> kernel have a say in the max size, if so, how can I
> find this limit.  Can I "cat" any of the /proc file     > to find this limit.
>

You can find this in /usr/include/linux/limits.h

#define NAME_MAX 255  /* # chars in a file name */
#define PATH_MAX 4096 /* # chars in a path name including nul */

nitin



--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive:       http://mail.nl.linux.org/kernelnewbies/
FAQ:           http://kernelnewbies.org/faq/



[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux