From 892ec928da3a0653ae54c321e4c3b1aa06c4e678 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. --- Xtranssock.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'Xtranssock.c') diff --git a/Xtranssock.c b/Xtranssock.c index bb1c792..ad3e116 100644 --- a/Xtranssock.c +++ b/Xtranssock.c @@ -99,6 +99,8 @@ from the copyright holders. #include #endif +#include + #else /* !WIN32 */ #include @@ -424,7 +426,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