Maximum length of userid on Fedora Linux
Miloslav Trmač
mitr at volny.cz
Tue Mar 30 19:04:24 UTC 2010
Kevin Kofler píše v Út 30. 03. 2010 v 20:51 +0200:
> Miloslav Trmač wrote:
> > Oh. In that case, use LOGIN_NAME_MAX from <limits.h> (256 on my
> > system).
>
> Does that include the terminating '\0' or should the buffer actually be
> sized LOGIN_NAME_MAX+1?
It doesn't really matter, the practical limit is so much smaller.
(man limits.h) doesn't say, but _POSIX_LOGIN_NAME_MAX does include the
terminating '\0', so LOGIN_NAME_MAX probably does as well.
Mirek
More information about the devel
mailing list