oops, corrupted memory again!

Sam Kendall sam at delftcc.UUCP
Wed Apr 30 01:06:17 AEST 1986


In article <4495 at cbrma.UUCP>, trl at cbrma.UUCP writes:
> 	Are there any "malloc" routines that check for modification of
> malloc's link pointers by the "user's" code?   Close to 70% of by bugs
> are stack/memory problems were I use more space than I allocated.  Tracking
> this kind of problem is horrible.
> ....
> 	This problem is not unique to my code, I know others that are
> plagued by these bugs also.  A programmer only needs one of these bugs
> in a large piece of software to waste a week of effort.
> ....
> 	I am interested in any tools, recommend tions, or routines that may
> help.  Thanks.

The Bcc Compiler, a tool made by Delft Consulting Corp., catches bugs of
this sort (as one case of "pointer out of bounds") and tells you exactly
where in your source the transgression occurred.  An item about Bcc was
recently posted to mod.newprod.  Please contact me for more info.

Also, if you have source, you can recompile malloc to check its internal
pointers stringently.  At least you could on V7, and I doubt anyone has
removed this capability.  This won't locate your bug, but it might help.

----
Sam Kendall			{ ihnp4 | seismo!cmcl2 }!delftcc!sam
Delft Consulting Corp.		ARPA:  delftcc!sam at NYU.ARPA
432 Park Avenue South		Phone: +1 212 243-8700
New York, NY  10016



More information about the Comp.lang.c mailing list