* 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.
			
			
This commit is contained in:
		@@ -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.
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user