From: ao950 AT FreeNet DOT Carleton DOT CA (Paul Derbyshire) Newsgroups: comp.os.msdos.djgpp Subject: Re: malloc() bug? Date: 30 Nov 1997 08:10:40 GMT Organization: The National Capital FreeNet Lines: 29 Message-ID: <65r720$f3t@freenet-news.carleton.ca> References: Reply-To: ao950 AT FreeNet DOT Carleton DOT CA (Paul Derbyshire) NNTP-Posting-Host: freenet5.carleton.ca To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Precedence: bulk "Tom Demmer" (DEMMER AT brain1 DOT lstm DOT ruhr-uni-bochum DOT de) writes: >> I am wondering if anyone out there has had the same problem: >> I am writing a program that need to dinamically allocate a huge number of >> little buffers (about 10 bytes each), but I have run into problem with >> malloc(), i receive SIGSEGV inside the malloc() code. >> The program code seems correct, and anyway it is not particularly >> complicate, it only performs some allocation and copy, so what it can be? >> Every malloc'ed pointer is free'ed up correctly. >> Is it a bug of malloc() function? Any suggestion? >> > > malloc() is pretty bug free and I never heard of SIGSEGVs inside > malloc when the user code was bug free. I have. On one 32-meg pentium I run Quake (the original, DJGPP-compiled) in a W95 DOS box with 65535 DPMI memory, -winmem 24, everything is fine. On the other computer with identical memory, I get SIGSEGV on startup at the "mallocing 24,987,654" stage. Difference is, Quake 1.08 on the one and 1.06 on the other (1.06 crashes). I suppose 1.06 might have a bug though that they fixed in 1.08? -- .*. Where feelings are concerned, answers are rarely simple [GeneDeWeese] -() < When I go to the theater, I always go straight to the "bag and mix" `*' bulk candy section...because variety is the spice of life... [me] Paul Derbyshire ao950 AT freenet DOT carleton DOT ca, http://chat.carleton.ca/~pderbysh