Maximum length of userid on Fedora Linux

drago01 drago01 at gmail.com
Sun Mar 28 13:09:47 UTC 2010


2010/3/28 Miloslav Trmač <mitr at volny.cz>:
> Jochen Schmitt píše v Ne 28. 03. 2010 v 11:38 +0200:
>> Am 27.03.2010 22:02, schrieb Miloslav Trmač:
>> > What's special about "16"?  Why not 8, 15, 17, 24, 32?
>> A user has reported a crash about blender on bugzilla.
>>
>> The examination of the bug shows, that there is a assignement where
>> a userid was copied into a array which is decleared as char [16], so
>> I though to memorize that I have read sometihing about 16 character
>> as a maximum for a userid on Unix.
> Oh.  In that case, use LOGIN_NAME_MAX from <limits.h> (256 on my
> system).

Or sysconf(_SC_LOGIN_NAME_MAX) to get the correct value at runtime for
the system you are running on.


More information about the devel mailing list