This is the mail archive of the
cygwin
mailing list for the Cygwin project.
How many fds can *you* open?
- From: Dan Kegel <dank at kegel dot com>
- To: cygwin at cygwin dot com
- Date: Sun, 21 Mar 2004 08:13:42 -0800
- Subject: How many fds can *you* open?
I'm having trouble on both my recently-updated cygwin
machines. They crash after opening 130 to 180 fds.
Here's a little program that just counts how many
fds it can open for /dev/null. I suspect a few of
you will also have my problem. Could you run this
and report back how many fds it reports, or whether it crashes?
Thanks,
Dan
#include <stdio.h>
#include <fcntl.h>
int main(int argc, char **argv)
{
int i;
for (i=0; open("/dev/null", O_RDONLY) != -1; i++)
;
printf("opened %d fds\n", i);
return 0;
}
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/