From owner-freebsd-questions Thu Jun 20 14:16:48 1996 Return-Path: owner-questions Received: (from root@localhost) by freefall.freebsd.org (8.7.5/8.7.3) id OAA09444 for questions-outgoing; Thu, 20 Jun 1996 14:16:48 -0700 (PDT) Received: from palmer.demon.co.uk (palmer.demon.co.uk [158.152.50.150]) by freefall.freebsd.org (8.7.5/8.7.3) with ESMTP id OAA09392 for ; Thu, 20 Jun 1996 14:15:53 -0700 (PDT) Received: from palmer.demon.co.uk (localhost [127.0.0.1]) by palmer.demon.co.uk (sendmail/PALMER-2) with ESMTP id VAA07075; Thu, 20 Jun 1996 21:53:51 +0100 (BST) To: James Raynard cc: af@biomath.jussieu.fr, freebsd-questions@freebsd.org From: "Gary Palmer" Subject: Re: Max first parameter of a Select call? In-reply-to: Your message of "Wed, 19 Jun 1996 14:04:20 GMT." <199606191404.OAA20852@jraynard.demon.co.uk> Date: Thu, 20 Jun 1996 21:53:50 +0100 Message-ID: <7073.835304030@palmer.demon.co.uk> Sender: owner-questions@freebsd.org X-Loop: FreeBSD.org Precedence: bulk James Raynard wrote in message ID <199606191404.OAA20852@jraynard.demon.co.uk>: > However, is a copy of the types.h used in compiling the > kernel, which is where the kernel picks up its value of FD_SETSIZE > from. So a user program can never safely use FD_SETSIZE > 256 without > a kernel re-compile first! It can actually, you get get an error back if you try to set the number of FD's you want to scan (the `nfds' parameter) to be greater than the value of FD_SETSIZE when the kernel was compiled (at least, that's how -stable works, and from a quick glance -current seems the same). The real answer is to make it dynamic and dependant on a read-only sysctl variable or something ... I'm not sure if the bitmap's required by the code will be that forgiving tho :-( Gary -- Gary Palmer FreeBSD Core Team Member FreeBSD: Turning PC's into workstations. See http://www.FreeBSD.ORG/ for info