delorie.com/archives/browse.cgi | search |
Mailing-List: | contact cygwin-help AT cygwin DOT com; run by ezmlm |
List-Subscribe: | <mailto:cygwin-subscribe AT cygwin DOT com> |
List-Archive: | <http://sources.redhat.com/ml/cygwin/> |
List-Post: | <mailto:cygwin AT cygwin DOT com> |
List-Help: | <mailto:cygwin-help AT cygwin DOT com>, <http://sources.redhat.com/ml/#faqs> |
Sender: | cygwin-owner AT cygwin DOT com |
Mail-Followup-To: | cygwin AT cygwin DOT com |
Delivered-To: | mailing list cygwin AT cygwin DOT com |
X-Injected-Via-Gmane: | http://gmane.org/ |
To: | cygwin AT cygwin DOT com |
From: | Nicholas Wourms <nwourms AT netscape DOT net> |
Subject: | BUG [cygwin(cvs)]: Segfault in fhandler_base when attempting to calculate |
maximum open files on WinME&2000 | |
Date: | Tue, 08 Jul 2003 20:22:05 -0400 |
Lines: | 47 |
Message-ID: | <befn62$ob4$1@main.gmane.org> |
Mime-Version: | 1.0 |
X-Complaints-To: | usenet AT main DOT gmane DOT org |
User-Agent: | Mozilla/5.0 (Windows; U; Win 9x 4.90; en-US; rv:1.4) Gecko/20030624 Netscape/7.1 (ax) |
X-Accept-Language: | en-us, en |
X-Enigmail-Version: | 0.76.1.0 |
X-Enigmail-Supports: | pgp-inline, pgp-mime |
Hi, There seems to be a nasty autoconf macro in coreutils (open-max.m4*) which attempts to compile and execute the following the code for the purpose of determining the system's simultaneous open file maximum: #include <stdio.h> #include <stdlib.h> #include <unistd.h> int main () { FILE *result = fopen ("conftest.omax", "w"); int i = 1; /* Impose an arbitrary limit, in case some system has no effective limit on the number of simultaneously open files. */ while (i < 30000) { FILE *s = fopen ("conftest.op", "w"); if (!s) break; ++i; } fprintf (result, "%d\n", i); exit (fclose (result) == EOF); } Executing the code segfaults with the following messages: 5 [main] foo 1008 cmalloc: cmalloc returned NULL 5004 [main] foo 1008 fhandler_base::set_name: fatal error. strdup failed Examining the binary in gdb reveals that it dies at line 1198 of fhandler.cc. This is 100% reproducable on a machine running WinME & another running Win2k SP4. The dll being used was built from cvs sources checked out today. Of course the test works fine on linux. Since this should be readily reproducable on any Cygwin platform running the most current sources & packages, I'm not going to flood the list with cygcheck. Cheers, Nicholas * You can also get it in m4 form from here: http://savannah.gnu.org/cgi-bin/viewcvs/*checkout*/coreutils/coreutils/m4/open-max.m4?rev=HEAD&content-type=text/plain -- 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/
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |