svn commit: r202143 - in head/sys: boot/forth compat/linux compat/svr4 i386/ibcs2 kern rpc security/audit sys

Brooks Davis brooks at FreeBSD.org
Tue Jan 12 08:05:07 UTC 2010


On Tue, Jan 12, 2010 at 07:49:35AM +0000, Brooks Davis wrote:
> Author: brooks
> Date: Tue Jan 12 07:49:34 2010
> New Revision: 202143
> URL: http://svn.freebsd.org/changeset/base/202143
> 
> Log:
>   Replace the static NGROUPS=NGROUPS_MAX+1=1024 with a dynamic
>   kern.ngroups+1.  kern.ngroups can range from NGROUPS_MAX=1023 to
>   INT_MAX-1.  Given that the Windows group limit is 1024, this range
>   should be sufficient for most applications.

With the commit, the only remaining delta to my projects/ngroups branch
is:

--- ../../head/sys/sys/param.h  2010-01-12 01:39:50.000000000 -0600
+++ ./sys/sys/param.h   2010-01-08 16:31:03.000000000 -0600
@@ -78,7 +78,6 @@
 #define        MAXLOGNAME      17              /* max login name length (incl. NUL) */
 #define        MAXUPRC         CHILD_MAX       /* max simultaneous processes */
 #define        NCARGS          ARG_MAX         /* max bytes for an exec function */
-#define        NGROUPS         (NGROUPS_MAX+1) /* max number groups */
 #define        NOFILE          OPEN_MAX        /* max open files per process */
 #define        NOGROUP         65535           /* marker for empty group set member */
 #define MAXHOSTNAMELEN 256             /* max hostname size */

which would remove the NGROUPS definition entirely.  Overall I think
this would be a good thing as applications should not be written with
NGROUPS or NGROUPS_MAX hard coded in, but I have not yet asked portmgr@
for a run to see how many ports this would break.  I do not believe
that NGROUPS is defined in any standard so removing it should only
break non-portable code.

-- Brooks
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 187 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/svn-src-all/attachments/20100112/4ffb827e/attachment.pgp


More information about the svn-src-all mailing list