Subject: Re: Maximum number of X server clients?
To: None <current-users@netbsd.org>
From: Christoph Badura <bad@ora.de>
List: current-users
Date: 05/07/1999 22:15:51
simonb@netbsd.org (Simon Burge) writes:

>Index: osdep.h
>===================================================================
>RCS file: /cvsroot/xsrc/xc/programs/Xserver/os/osdep.h,v
>retrieving revision 1.1.1.3
>diff -p -u -r1.1.1.3 osdep.h
>--- osdep.h	1998/11/23 15:40:36	1.1.1.3
>+++ osdep.h	1999/05/07 12:07:53
>@@ -110,8 +110,8 @@ SOFTWARE.
> #endif
> #endif
> 
>-/* ignore OPEN_MAX on FreeBSD, it's bogusly low */
>-#if OPEN_MAX <= 128 && !defined(__FreeBSD__)
>+/* ignore OPEN_MAX on FreeBSD and NetBSD, it's bogusly low */
>+#if OPEN_MAX <= 128 && !(defined(__FreeBSD__) || defined(__NetBSD__))
> #define MAXSOCKS (OPEN_MAX - 1)
> #else
> #define MAXSOCKS 128

hmm, the soft limit for open files seems to be 64.  Why not make the
code DTRT thing and limit this at the X servers's open files resource limit?
(Or submit a PR on this.)
-- 
Christoph Badura					www.netbsd.org

	Anything that can be done in O(N) can be done in O(N^2).
	-- Ralf Schuettau (after looking at a particular piece of code)