Re: please describe ASExecuteEvent, UASLookupIDForScript
Re: please describe ASExecuteEvent, UASLookupIDForScript
- Subject: Re: please describe ASExecuteEvent, UASLookupIDForScript
- From: Shane Stanley <email@hidden>
- Date: Wed, 21 May 2014 09:13:44 +1000
On 21 May 2014, at 3:55 am, bill metzinger <email@hidden> wrote:
> i have an app that parses tons of data and does magic tricks
>
> it runs great with smaller amounts of data
>
> but when it runs for several minutes with tons of data it crashes like this :
>
>
> ##############
> Exception Type: EXC_BAD_ACCESS (SIGSEGV)
> Exception Codes: KERN_INVALID_ADDRESS at 0x0000000000000002
>
> VM Regions Near 0x2:
> -->
> __TEXT 0000000106710000-0000000106711000 [ 4K] r-x/rwx SM=COW
>
> Application Specific Information:
> Performing @selector(ButtonClickRun:) from sender NSButton 0x60000015c1a0
>
> Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
> 0 com.apple.applescript UASLookupIDForScript(TUASScript const*) + 51
> 1 com.apple.applescript UASRemoteSend(unsigned char, unsigned char, unsigned char, unsigned char, unsigned char, unsigned char*) + 163
> 2 com.apple.applescript UASActor_Send(unsigned char, unsigned char, unsigned char) + 396
> 3 com.apple.applescript UASValue_Send(unsigned char, unsigned char, TUASClassIndex, unsigned char) + 329
> 4 com.apple.applescript UASExecute1() + 321
> 5 com.apple.applescript ASExecuteEvent(AEDesc const*, unsigned int, int, unsigned int*) + 625
> 6 com.apple.applescript AppleScriptComponent + 845
> 7 com.apple.openscripting OSAExecuteEvent + 70
> 8 com.apple.AppleScriptObjC +[BAObjectProto invokeScriptHandler:forObject:inComponentInstance:args:error:] + 222
> 9 com.apple.AppleScriptObjC -[BAObjectProto invokeScriptHandler:args:error:] + 114
> 10 com.apple.AppleScriptObjC -[BAObjectProto forwardInvocation:] + 383
> 11 com.apple.CoreFoundation ___forwarding___ + 452
> 12 com.apple.CoreFoundation _CF_forwarding_prep_0 + 120
> ##############
>
>
> i can't find any documentation on UASLookupIDForScript
You're unlikely too. Most of that stuff is private methods and functions.
> i'm trying to figure out what it's doing at the time of the crash
>
> the line that says : ASExecuteEvent(AEDesc const*, unsigned int, int, unsigned int*)
>
> does it mean that one of my handlers was just called with four parameters ?
No, it means an an AppleEvent was sent.
> or is my problem unrelated to what was going on and more related to memory deallocation
>
> i've had this crash with xcode 4 running on lion with and without garbage collection
>
> now on xcode 5 and 10.9 with and without arc i'm having the same crashes
My suspicion is that these types crashes happen when AppleScript starts doing its own garbage collection. If I'm right, there's probably nothing you can do about it other than (a) log bug reports, and (b) see if there's any way you can avoid converting a lot of that data to AppleScript objects where you don't need to.
--
Shane Stanley <email@hidden>
<www.macosxautomation.com/applescript/apps/>
_______________________________________________
Do not post admin requests to the list. They will be ignored.
applescriptobjc-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden