I apprieciate your comments on the debugging, but this error happens before
my PilotMain method, so there is no break point to set.  I select debug in
the error window and I get a registry dump, that is pretty much Greek to me.
It is in assembler...  I do not know assembler.  No mention of what method
it is crashing on.

I could not find a way to send the stack dump, so you could look at it.  

As for the C course... I have been programming C/C++ for 15 years.  Have
also taught C/C++ for 9 years at the local university.

There appear to be lots of little issues to this palm os set of libraries,
that the newbie (me) trying to pick them up, is in need of assistance.  I
have filled in the palm os development agreement, but am two weeks from
getting any source code available to me.  I would rather not wait two weeks
to answer these questions.  I try to debug the code as best I can.  When I
come to a wall I chuck a note over the wall hoping for help.  

Thanks
Dean-O




-----Original Message-----
From: David Fedor [mailto:[EMAIL PROTECTED]]
Sent: Monday, February 12, 2001 2:43 PM
To: Palm Developer Forum
Subject: RE: Table.c Line:2153, Invalid Parameter


>Well I did this... so I have to wait 2 weeks to get the answer to this one?

Not at all.  Try using a debugger; if you're running one when you cause the
problem then you can look at a stack trace and find out what you're
calling, and thereby figure out what's going wrong.

Basic debugging techniques apply: step through your code, set breakpoints,
look at the values of parameters you're passing.  If these are concepts
you're not familiar with, you really should consider taking a good C
course, since otherwise we could get you over this hump but you'd just hit
another one in an hour.  Debugging isn't PalmOS-specific thing.

There are times that the debugging messages aren't clear and so having the
OS source helps greatly, but when one says "Invalid Parameter" then you
should check the parameters you're passing in to the function which is
complaining, since odds are high that one or more of them is invalid :-)

"Chunk under-locked" means you're calling unlock on a handle that isn't
locked.  With the debugger you'll probably find easily which line of your
code is trying to call MemHandleUnlock (or MemPtrUnlock) to unlock
something that isn't locked.  Or calling a routine which does the same.

Caveat - if something has corrupted the heap, you could get these sorts of
things going haywire for other reasons.  Again, use standard C techniques
to debug trashing memory, plus use latest versions of the Palm OS Emulator
to help you debug it, in combination with your normal debugger.

-David Fedor
Palm Developer Support

-- 
For information on using the Palm Developer Forums, or to unsubscribe,
please see http://www.palmos.com/dev/tech/support/forums/

-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/tech/support/forums/

Reply via email to