From e5b4532ab8576dd0927e3f549a1546fb3b37d8e1 Mon Sep 17 00:00:00 2001 From: Adam Jackson Date: Thu, 7 Aug 2008 10:32:11 -0400 Subject: Drastically simplify TRANS_OPEN_MAX. If your OS doesn't have sysconf(3), then life is already hard for you. Backported-to-NX-by: Ulrich Sibiller --- nx-X11/lib/xtrans/Xtranssock.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'nx-X11/lib/xtrans/Xtranssock.c') diff --git a/nx-X11/lib/xtrans/Xtranssock.c b/nx-X11/lib/xtrans/Xtranssock.c index 3e4896fce..cdc421a1e 100644 --- a/nx-X11/lib/xtrans/Xtranssock.c +++ b/nx-X11/lib/xtrans/Xtranssock.c @@ -141,6 +141,8 @@ from the copyright holders. #include #endif +#include + #else /* !WIN32 */ #include @@ -993,7 +995,7 @@ TRANS(SocketOpen) (int i, int type) Sockettrans2devtab[i].protocol)) < 0 #ifndef WIN32 #if (defined(X11_t) && !defined(USE_POLL)) || defined(FS_t) || defined(FONT_t) - || ciptr->fd >= TRANS_OPEN_MAX + || ciptr->fd >= sysconf(_SC_OPEN_MAX) #endif #endif ) { -- cgit v1.2.3