> As Keith suggested, you can try adjusting the amount of stack space your
> app gets.
Actually, I forgot that this was occuring during reset. The application uses
the OS's stack at that time, not its own, so setting the 'pref' resource like I
suggested won't help.
And since Mitch is handling only sysAppLaunchCmdNormalLaunch and
sysAppLaunchCmdFind commands, it sounds like his application is not responsible
at all for the stack overflow.
Mitch, what version of the emulator and OS are you using? Palm OS Emulator
3.0a8 works around a problem in Palm OS 3.3 where the OS of its own accord would
overflow the stack during a reset.
-- Keith Rollin
-- Palm OS Emulator engineer
Peter Epstein <[EMAIL PROTECTED]> on 12/19/2000 04:01:32 PM
Please respond to "Palm Developer Forum" <[EMAIL PROTECTED]>
Sent by: Peter Epstein <[EMAIL PROTECTED]>
To: "Palm Developer Forum" <[EMAIL PROTECTED]>
cc: (Keith Rollin/US/PALM)
Subject: RE: Stack Overflow on Reset
At 03:26 AM 12/19/2000, Mitch Fawcett wrote:
>By "PalmDebugger", are you referring to what is documented in the ..\Palm OS
>Documentation\Palm OS Debugging on WIn.pdf? That is the document that shows
>how to use the console commands.
>
>Console commands are something I haven't resorted to up until now.
PalmDebugger is available for Mac and Windows. I don't think it's documented in
a pdf file, but I could be wrong. It's included in the SDK under an Unsupported
folder. It isn't as easy to use as a source level debugger like CodeWarrior has,
but in some cases, it's the best tool for the job.
>I'm not doing anything (that I know of) tricky or otherwise on a reset. Here
>are the launch commands I specifically handle in PilotMain:
>sysAppLaunchCmdNormalLaunch
>sysAppLaunchCmdFind (the flag sysAppLaunchFlagNewGlobals is examined in my
>code)
Okay, so it sounds like your app is just using a lot of stack space. Could be
two things: infinite recursion or just using too much stack. As Keith suggested,
you can try adjusting the amount of stack space your app gets. To reduce stack
space consumption, don't allocate big things on the stack. This includes
parameters and temporary variables. In some cases, this means using the dynamic
heap instead of the stack. In other cases it means passing pointers instead of a
struct.
--
Peter Epstein
Palm Inc. Developer
--
For information on using the Palm Developer Forums, or to unsubscribe, please see
http://www.palmos.com/dev/tech/support/forums/