Well, I've gotten extremely deep into the bug this thread started
with (occurrence of the error message "Form.c, Line:649, Windows
cannot be under forms because they
can't be redrawn" under a debug OS 3.5 ROM). But not deep enough
-- I still haven't solved it.
As stated in the original posting, this CodeWarrior application
is large, a nearly 200k database. It contains multiple segments,
and uses the "smart" code model. It is in C++.
While keeping nearly all the code in the application intact, I
have been able to reduce the actual execution path so that it
just calls FrmAlert immediately after being launched. Upon
dismissing the alert, I get the above-cited error message.
In the app's starter module (containing PilotMain()), I can trim
out some code (none of which is being executed in this
drastically shortened execution path) and reach a version where
the error message no longer occurs. The cutting can be done
several ways; I've tried to find patterns, but so far haven't
succeeded. I thought for a while that it was a simple matter of
the code size exceeding some threshold, but have disproved
that. I've tried going Large Model, and splitting up segments;
neither affects the behavior. Upon reaching a version of the
module that didn't cause the error, I tried putting a bunch of
lines of irrelevant (non-executed) code back in just to swell the
size, but didn't succeed in making the error happen again.
Whereas adding back certain other, less voluminous but still
unexecuted, lines of code *did* bring the error back.
I've spent a lot of time debugging through operating system code,
starting with the call to FrmAlert. I'm doing it on Windows,
hence don't have PalmDebugger with its ability to set breakpoints
on traps. It's been exceedingly tedious -- since CodeWarrior and
the Emulator together don't provide any capability for
breakpoints within system code, I haven't seen anything to do
except single-step through it. I know that the error occurs
somewhere within FrmEraseForm or something it
calls. Unfortunately, this routine has changed pretty radically
between PalmOS 3.0 (to which I have the distributed source) and
3.5, and it's hard to tell just what's going on in there.
I could probably spend another 20 hours in this morass, but would
like to preserve my sanity.
Once again: does anyone have some advice for me?
Thanks in advance,
Greg Lutz
--
For information on using the Palm Developer Forums, or to unsubscribe, please see
http://www.palm.com/devzone/mailinglists.html