Provide more correct default values for sysconf(3) reporting of the AIO

subsystems capabilities:

_SC_AIO_LISTIO_MAX returns the default of _POSIX_AIO_LISTIO_MAX
_SC_AIO_MAX returns the default _POSIX_AIO_MAX
_SC_AIO_PRIO_DELTA_MAX returns the default of 0

Without these adjustments the values returned are -1 even when the
aio side of the kernel returns '0' for them which is incorrect.

Noticed by: Craig Rodrigues <rodrigc@attbi.com>
This commit is contained in:
Alfred Perlstein 2002-11-16 06:35:20 +00:00
parent c844abc920
commit 3d8ce33a50
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=106976

View File

@ -254,14 +254,17 @@ sysconf(name)
return (_POSIX_TIMERS);
#endif
case _SC_AIO_LISTIO_MAX:
defaultresult = _POSIX_AIO_LISTIO_MAX;
mib[0] = CTL_P1003_1B;
mib[1] = CTL_P1003_1B_AIO_LISTIO_MAX;
goto yesno;
case _SC_AIO_MAX:
defaultresult = _POSIX_AIO_MAX;
mib[0] = CTL_P1003_1B;
mib[1] = CTL_P1003_1B_AIO_MAX;
goto yesno;
case _SC_AIO_PRIO_DELTA_MAX:
defaultresult = 0;
mib[0] = CTL_P1003_1B;
mib[1] = CTL_P1003_1B_AIO_PRIO_DELTA_MAX;
goto yesno;