Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , 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-pair-Authenticated: 24.126.73.164 Message-ID: <405D3CEA.3090006@kegel.com> Date: Sat, 20 Mar 2004 22:57:46 -0800 From: Dan Kegel User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.6) Gecko/20040113 MIME-Version: 1.0 To: cygwin AT cygwin DOT com Subject: Re: Minimal test case for Make crash bug References: <405C00BF DOT 3090507 AT kegel DOT com> <405C06C4 DOT 7030508 AT kegel DOT com> <405C6C4B DOT 90409 AT kegel DOT com> <405C939E DOT 5020909 AT kegel DOT com> <405D1ACD DOT 4060809 AT kegel DOT com> In-Reply-To: <405D1ACD.4060809@kegel.com> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Dan Kegel wrote: > int main(int argc, char **argv) > { > int i; > for (i=0; ; i++) { > int fd = open("foo.c", O_RDONLY); > printf("fd #%d is %d\n", i, fd); > } > } > > This crashes for me at the 133rd fd unless I run it under gdb ... OK, I built a debugging version of cygwin1.dll and dropped it on top of the normal one, then ran my test program with export CYGWIN=error_start:C:\\cygwin\\bin\\gdb.exe ./foo and hit 'c' and then 'bt' as suggested. Looks like the debugger is a bit happier with the debugging build. I don't have time to look at it tonight, but in case it makes any sense to you, here's the backtrace. Thanks, Dan Program received signal SIGSEGV, Segmentation fault. [Switching to thread 660.0x838] fhandler_base::fhandler_base() (this=0x0) at ../../../../cygwin-snapshot-20040318-1/winsup/cygwin/fhandler.cc:1275 1275 { Current language: auto; currently c++ (gdb) bt #0 fhandler_base::fhandler_base() (this=0x0) at ../../../../cygwin-snapshot-20040318-1/winsup/cygwin/fhandler.cc:1275 #1 0x61031854 in fhandler_disk_file::fhandler_disk_file() (this=0x0) at ../../../../cygwin-snapshot-20040318-1/winsup/cygwin/fhandler_disk_file.cc:379 #2 0x6101e174 in build_fh_pc(path_conv&) (pc=@0x22ec90) at ../../../../cygwin-snapshot-20040318-1/winsup/cygwin/fhandler.h:311 #3 0x6101ded8 in build_fh_name(char const*, void*, unsigned, suffix_info*) ( name=0x401050 "foo.c", h=0x0, opt=1, si=0x0) at ../../../../cygwin-snapshot-20040318-1/winsup/cygwin/dtable.cc:351 #4 0x61095071 in open (unix_path=0x401050 "foo.c", flags=0) at ../../../../cygwin-snapshot-20040318-1/winsup/cygwin/syscalls.cc:550 #5 0x610883cf in _sigfe () at ../../../../cygwin-snapshot-20040318-1/winsup/cygwin/cygserver.h:82 #6 0x00000085 in ?? () #7 0xffffffff in ?? () #8 0x0022f070 in ?? () -- 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/