views:

1799

answers:

3

I have a swf that is being loaded by a third party swf. I have source code and recompile my swf, but don't have code to the third party swf.

Somewhere, likely in my code, there's a stack overflow. In a debug flash player, I get a nice popup dialog with a stack trace when the overflow occurs:

Error: Error #1023: Stack overflow occurred.
    at Object$/Object::_hasOwnProperty()
    at Object/http://adobe.com/AS3/2006/builtin::hasOwnProperty()
    at Object$/Object::_hasOwnProperty()
    at Object/http://adobe.com/AS3/2006/builtin::hasOwnProperty()
    at Object$/Object::_hasOwnProperty()

It goes on like this for 64 lines. However, it looks like I'm only seeing the last 64 stack frames, not the whole stack trace.

Is there a way to see the full stack trace? As an alternative, is there a way to limit the stack depth?

I've spent a full day trying to debug this, but am running on very little information, and a lack of tools. Here's what I've tried:

  • Hooking my code up to a debugger. This is in flash 9.0.28 running in windows inside a VM, connecting to flex builder running outside the VM. It appears to connect, but I don't get trace statements, and breakpoints don't fire.
  • Sending log lines to an http server. This works, but I suspect I'm missing the last n stack frames before the overflow/server crash.
  • A blind, binary search type approach disabling portions of code - this is slow, but probably will work.

Any other strategies I should be trying?

+3  A: 

Does this sounds like the same problem? Sorry as it's not directly an answer on how you could further debug this but more a pointer to someone who had a similar problem and found a solution.

lpfavreau
This did end up being our problem, thanks! What a gnarly bug...
Scotty Allen
A: 

This might also be of help.

Luke
A: 

Hi,

I posted an workaround description for Flash-dummies like me.

http://bugs.adobe.com/jira/browse/FP-939#action%5F304741

-eric

buri