Re: What could cause this to fail under MallocScribble?
Re: What could cause this to fail under MallocScribble?
- Subject: Re: What could cause this to fail under MallocScribble?
- From: "Sean McBride" <email@hidden>
- Date: Wed, 18 Jun 2008 10:14:40 -0400
- Organization: Rogue Research
On 6/17/08 10:27 PM, Ken Thomases said:
>The malloc man page is slightly out of date with respect to
>MallocDebug. If you use the MallocHelp variable to ask MallocDebug to
>print out its true, current usage guide, it provides:
>
>$ MallocHelp=1 /usr/bin/true
>true(5867) malloc: environment variables that can be set for debug:
>- MallocLogFile <f> to create/append messages to file <f> instead of
>stderr
>- MallocGuardEdges to add 2 guard pages for each large block
>- MallocDoNotProtectPrelude to disable protection (when previous flag
>set)
>- MallocDoNotProtectPostlude to disable protection (when previous flag
>set)
>- MallocStackLogging to record all stacks. Tools like leaks can then
>be applied
>- MallocStackLoggingNoCompact to record all stacks. Needed for
>malloc_history
>- MallocScribble to detect writing on free blocks and missing
>initializers:
> 0x55 is written upon free and 0xaa is written on allocation
>- MallocCheckHeapStart <n> to start checking the heap after <n>
>operations
>- MallocCheckHeapEach <s> to repeat the checking of the heap after <s>
>operations
>- MallocCheckHeapSleep <t> to sleep <t> seconds on heap corruption
>- MallocCheckHeapAbort <b> to abort on heap corruption if <b> is non-
>zero
>- MallocErrorAbort to abort on a bad malloc or free
>- MallocHelp - this help!
Actually, I think that info is even more out of date because it doesn't
even mention MallocPreScribble. According to TN2124, MallocPreScribble
was only added in 10.4:
<http://developer.apple.com/technotes/tn2004/tn2124.html#SECMALLOC>
On the other hand, though it seems older, it seems to be describing
actual behaviour. Maybe MallocPreScribble doesn't actually do anything?!
One thing is sure, these docs need to be made self-consistent... :)
--
____________________________________________________________
Sean McBride, B. Eng email@hidden
Rogue Research www.rogue-research.com
Mac Software Developer Montréal, Québec, Canada
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden