mirror of
https://git.FreeBSD.org/src.git
synced 2024-12-20 11:11:24 +00:00
Implement sysconf(_SC_GETGR_R_SIZE_MAX) and sysconf(_SC_GETPW_R_SIZE_MAX).
Reported by: Dmitry Sivachenko <trtrmitya@gmail.com> Sponsored by: The FreeBSD Foundation MFC after: 1 week
This commit is contained in:
parent
a91831a261
commit
a028ee5c9f
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=268467
@ -367,11 +367,17 @@ sysconf(name)
|
||||
* _POSIX_FILE_LOCKING, so we can't answer this one.
|
||||
*/
|
||||
#endif
|
||||
#if _POSIX_THREAD_SAFE_FUNCTIONS > -1
|
||||
|
||||
/*
|
||||
* SUSv4tc1 says the following about _SC_GETGR_R_SIZE_MAX and
|
||||
* _SC_GETPW_R_SIZE_MAX:
|
||||
* Note that sysconf(_SC_GETGR_R_SIZE_MAX) may return -1 if
|
||||
* there is no hard limit on the size of the buffer needed to
|
||||
* store all the groups returned.
|
||||
*/
|
||||
case _SC_GETGR_R_SIZE_MAX:
|
||||
case _SC_GETPW_R_SIZE_MAX:
|
||||
#error "somebody needs to implement this"
|
||||
#endif
|
||||
return (-1);
|
||||
case _SC_HOST_NAME_MAX:
|
||||
return (MAXHOSTNAMELEN - 1); /* does not include \0 */
|
||||
case _SC_LOGIN_NAME_MAX:
|
||||
|
Loading…
Reference in New Issue
Block a user