From: broeker AT acp3bf DOT knirsch DOT de (Hans-Bernhard Broeker) Newsgroups: comp.os.msdos.djgpp Subject: Re: sscanf() fluffs my program up ! Date: 6 Sep 1999 14:51:48 +0200 Organization: RWTH Aachen, III. physikalisches Institut B Message-ID: <7r0dd4$682@acp3bf.knirsch.de> References: <199909021957 DOT UAA00512 AT burdock DOT restall DOT net> NNTP-Posting-Host: acp3bf.physik.rwth-aachen.de X-Trace: nets3.rz.RWTH-Aachen.DE 936622311 13564 137.226.32.75 (6 Sep 1999 12:51:51 GMT) X-Complaints-To: abuse AT rwth-aachen DOT de NNTP-Posting-Date: 6 Sep 1999 12:51:51 GMT X-Newsreader: TIN [version 1.2 PL2] Lines: 23 To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com Peter Restall (pete AT restall DOT net) wrote: > On Thu, 2 Sep 1999 11:10:02 +0300 (IDT), Eli replied: > > If you cannot figure this out, please post a complete short program > > that can be compiled and debugged, and which exhibits this behavior. > > Then someone will probably find the problem. > That might be kinda hard. I'm making a 3D engine, and I've got a couple of > hundred kilobytes of source. So what? Not all of those are going to be used in the minimal program that still shows the bug. Actually, odds are rather high that you'll find the error yourself, while cutting the program down to the 'necessary' pieces. Just have a careful look at each program line that turns out to kill the bug, if you remove that line. Another hint: get yourself 'Checker-gcc' for linux, and send your program through it. That special version of gcc is quite good at detecting any kind of overwriting memory that shouldn't be touched (buffer over/underflow), or reads of uninitialized memory. -- Hans-Bernhard Broeker (broeker AT physik DOT rwth-aachen DOT de) Even if all the snow were burnt, ashes would remain.