Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCorinna Vinschen <corinna@vinschen.de>2001-08-16 18:20:09 +0400
committerCorinna Vinschen <corinna@vinschen.de>2001-08-16 18:20:09 +0400
commit3171175e90d908fd5be0da43af7aa427701d45b6 (patch)
tree39c083e9990369ccf70baad8ede312404504fcad /winsup/cygwin/include
parent91a1423a877aa2464b290cc42f362ffa6f46d434 (diff)
* resource.cc (getrlimit): Return OPEN_MAX as current limit
on RLIMIT_NOFILE. * syscalls.cc (getdtablesize): Return OPEN_MAX. * sysconf.cc (sysconf): Return OPEN_MAX on _SC_OPEN_MAX. * include/limits.h (OPEN_MAX): Define as 256.
Diffstat (limited to 'winsup/cygwin/include')
-rw-r--r--winsup/cygwin/include/limits.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/winsup/cygwin/include/limits.h b/winsup/cygwin/include/limits.h
index 397ba2030..4a2ad3a8d 100644
--- a/winsup/cygwin/include/limits.h
+++ b/winsup/cygwin/include/limits.h
@@ -122,6 +122,13 @@ details. */
This limits how many children we can fork/spawn off. */
#define CHILD_MAX 63
+/* # of open files per process. Actually it can be more since Cygwin
+ grows the dtable as necessary. We define a reasonable limit here
+ which is returned by getdtablesize(), sysconf(_SC_OPEN_MAX) and
+ getrlimit(RLIMIT_NOFILE). */
+#undef OPEN_MAX
+#define OPEN_MAX 256
+
/* POSIX values */
/* These should never vary from one system type to another */
/* They represent the minimum values that POSIX systems must support.