Re: NSAppleScript leaking memory?
Re: NSAppleScript leaking memory?
- Subject: Re: NSAppleScript leaking memory?
- From: Andreas Mayer <email@hidden>
- Date: Mon, 29 Mar 2004 07:08:42 +0200
More info on the NSAppleScript leak issue.
1. Removing the separate thread didn't change anything.
2. I looked at my app with MallocDebug and Sampler.
MallocDebug doesn't report any leaks at all. I suppose that is related
to it's limitation outlined in the leaks man page:
However, Mal-
locDebug does not detect leaks in circularly-linked structures or
iden-
tify groups of leaked, connected nodes; leaks's pointer analysis
can cor-
rectly identify such leaks.
3. While running Sampler I got this in the console log:
*** Strange allocation log at index 1190511: there was already an
allocation log for 0x5a0b1c0 at index 1179823. This maybe normal if it
happens only the first time the allocation machinery is injected, but
may be a real error if it keeps reoccurring for that process.
Old stack: 0x00037d36 malloc_zone_malloc | malloc | operator
new(unsigned long) | AEDescImpl::duplicate() const |
AERecordImpl::AERecordImpl[unified](AERecordImpl const*) |
AERecordImpl::duplicate() const | AEDuplicateDesc |
aeCoerceDescInternal(AEDesc const*, unsigned long, AEDesc*, unsigned
char) | AECoerceDesc | ComponentCoerceDesc(AEDesc const*, unsigned
long, AEDesc*) | DecodeObjectSpecifier(AEDesc const*) |
DecodeAEDescInternal(AEDesc const*, TUASDecodeState) |
DecodeObjectSpecifier(AEDesc const*) | DecodeAEDescInternal(AEDesc
const*, TUASDecodeState) | DecodeObjectSpecifier(AEDesc const*) |
DecodeAEDescInternal(AEDesc const*, TUASDecodeState) |
UASDecodeReply(TStackFrame_UASRemoteSend*, short, AEDesc*, unsigned
char*) | UASRemoteSend(unsigned char, unsigned char, unsigned char,
unsigned char, unsigned char, unsigned char*) |
UASRemoteGetData(TUASObjectAlias*, TUASApplication*,
TUASClassIdentifier*, unsigned char*) |
UASGetDataNoCircularities(unsigned char, TUASClassIdentifier*) |
UASGetData(unsigned char, TUASClassIdentifier*) | UASExecute1() |
UASExecute(unsigned char) | ASExecute(unsigned long, unsigned long,
long, unsigned long*) | CallComponentFunctionCommon |
AppleScriptComponent | CallComponent |
AGenericManager::HandleOSACall(ComponentParameters*) | GenericComponent
| CallComponent | OSAExecute | -[NSAppleScript executeAndReturnError:]
| 0x6416c4 | forkThreadForFunction | _pthread_body | 0x0 | 0x182e001 |
New stack: 0x0003b1e1 malloc_zone_malloc | malloc | operator
new(unsigned long) | AEImpl::decodeMessage(DescriptorBundleDecoder*) |
AEListImpl::AEListImpl[unified](DescriptorBundleDecoder*) |
AEImpl::decodeMessage(DescriptorBundleDecoder*) |
AERecordImpl::AERecordImpl[unified](DescriptorBundleDecoder*) |
AEEventImpl::AEEventImpl[unified](DescriptorBundleDecoder*) |
AEImpl::decodeMessage(DescriptorBundleDecoder*) | AEProcessMessage |
waitForReply(unsigned, WaitForReplyElem*, unsigned long) |
AESendMessage | aeSend | AESend | AEDefaultSendProc(AEDesc const*,
AEDesc*, long, short, long, unsigned char (*)(EventRecord*, long*,
OpaqueRgnHandle**), unsigned char (*)(EventRecord*, long, long, AEDesc
const*), long) | InvokeOSASendUPP | ComponentSend(AEDesc const*,
AEDesc*, long, long) |
TUASApplication::Send(TStackFrame_UASRemoteSend*, AEDesc*, AEDesc*,
unsigned char, unsigned char, unsigned char) |
ForwardEventToSystem(TStackFrame_UASRemoteSend*, AEDesc*, AEDesc*,
unsigned char, unsigned char, unsigned char) |
TUASApplication::Send(TStackFrame_UASRemoteSend*, AEDesc*, AEDesc*,
unsigned char, unsigned char, unsigned char) | UASRemoteSend(unsigned
char, unsigned char, unsigned char, unsigned char, unsigned char,
unsigned char*) | UASRemoteGetData(TUASObjectAlias*, TUASApplication*,
TUASClassIdentifier*, unsigned char*) |
UASGetDataNoCircularities(unsigned char, TUASClassIdentifier*) |
UASGetData(unsigned char, TUASClassIdentifier*) | UASExecute1() |
UASExecute(unsigned char) | ASExecute(unsigned long, unsigned long,
long, unsigned long*) | CallComponentFunctionCommon |
AppleScriptComponent | CallComponent |
AGenericManager::HandleOSACall(ComponentParameters*) | GenericComponent
| CallComponent | OSAExecute | -[NSAppleScript executeAndReturnError:]
| 0x6416c4 | forkThreadForFunction | _pthread_body | 0x0 | 0x187f201 |
Needless to say, this happened not only once but filled my log with
hundreds of entries ...
I'm really at the end of my abilities. This looks like something that
Apple's engineers will have to sort out.
Andreas
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.