The weird thing is that under the debugger it is able to run, although it stops at one point. When I try to just run it, it dies with the odd address error. Any ideas on how to understand where I went wrong? Addresses for
Err = $D0                                (value = 0)
ro = $D5    << odd address?    (value == 2)
Path = 0x002f1744 (value == "/COMPLIFE/GO.PRM" and file is present)
volRefNum = 0x00106888    (value == 1)

I've tried adding in a dummy char both before and after ro since it has an odd address, to no avail.


void filebase::Open(const char *Name,bool ReadOnly)
{

if (!FindVolRefNum())    // sets static variable volRefNum
  throw(ExceptionError("data files not found on this system"));

UInt16 ro = ReadOnly ? vfsModeRead : vfsModeReadWrite;
Err err;
char Path[200];
strcpy(Path,"/COMPLIFE/");
strcat(Path,Name);
err = VFSFileOpen (volRefNum,Path, ro,&Handle);
<<<< Debugger stops on return of this call, as though an error occured in VFSFileOpen, with gray arrow. I'm guessing this is where the error is.



Chris Bruner
Compulife Software Inc.
==============================================
----- Original Message ----- From: "Robert Moynihan" <[EMAIL PROTECTED]>
To: "Palm Developer Forum" <[email protected]>
Sent: Tuesday, October 11, 2005 4:02 PM
Subject: Re: odd address error


cbruner wrote:

I'm getting an
Emul68KCommon.c,
Line:839, Odd address

I don't have any file called Common.c, so I'm at a bit of a loss as to how to debug this.

The error is being DETECTED in that module, but it almost assuredly is coming from you code... somewhere.


Also when I'm debugging I don't get this error, however the debugger will stop at places that I haven't set any breakpoints for. Are these related?

You've probably corrupted some random memory location and are getting various errors. You are just going to have to troubleshoot this to find the cause -- probably comment out successive large blocks of code to detect where the bug is hiding.

Bob

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




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

Reply via email to