Date: Tue, 18 Apr 2000 20:04:26 +0600 (LKT) From: Kalum Somaratna aka Grendel X-Sender: root AT darkstar DOT grendel DOT net To: djgpp AT delorie DOT com cc: vdaanen AT chru-lille DOT fr Subject: Re: Malloc problems In-Reply-To: <8074D95288C2D311AC660000F8106CC8EA7BE0@MSG1CHR> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Reply-To: djgpp AT delorie DOT com Errors-To: nobody AT delorie DOT com X-Mailing-List: djgpp AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk On Tue, 18 Apr 2000, DAANEN Vincent wrote: > Hi > recently, I downloaded gcc 2.95.2 for djgpp. Some programs those > worked fine when compiled with gcc -2.7.. or gcc 2.8.. > do not work now. They break in malloc functions > Is there a bug in malloc of gcc 2.95.2 ? > Is there a patch ? This almost certainly is due to your programe overwriting buffers allocated with malloc or call free more than once with the same pointer. This is because of the malloc version in DJGPP v2.02 doesn't waste memory. BTW there is a tool called YAMD available from which helps to catch just such bugs. Please read the FAQ section 9.2 for more information. Grendel. Hi, I'm a signature virus. plz set me as your signature and help me spread :)