Just fixed it useing :
#include "MemGlue.h"
void *operator new(UInt32 size) {
void *ptr = MemGluePtrNew(size);
MemSet(ptr, 0, size);
return ptr;
}
----- Original Message -----
From: "Chris Apers" <[EMAIL PROTECTED]>
To: "Palm Developer Forum" <[EMAIL PROTECTED]>
Sent: Wednesday, August 25, 2004 4:22 PM
Subject: Re: big object allocation (was MTWK::__LoadAndRelocate__ problem)
> Ok, i found the problem, i'm allocation a big object (71k)
> with the new operator and it failed.
>
> Any way to allocate a big object (override the new operator)
> with all constructor call ?
>
> Thanks a lot
> Chris
>
>
> ----- Original Message -----
> From: "Chris Apers" <[EMAIL PROTECTED]>
> To: "Palm Developer Forum" <[EMAIL PROTECTED]>
> Sent: Wednesday, August 25, 2004 2:58 PM
> Subject: MTWK::__LoadAndRelocate__ problem
>
>
> > Hi,
> >
> > When i run my program i have a :
> > Invalid read from 00004F18
> >
> > The debugger stack shows :
> > __Startup__
> > MTWK::__LoadAndRelocate__(unsigned char,__opaque*)
> >
> > Source :
> > ...
> > ...
> > 03298038: 2F0A move.l a2,-(a7)
> > 0329803A: 4E4F trap #15
> > 0329803C: A022 sysTrapMemHandleUnlock
> > 0329803E: 584F addq.w #4,a7
> > 03298040: 7010 moveq #16,d0
> > 03298042: D880 add.l d0,d4
> > 03298044: 5246 addq.w #1,d6
> > 03298046: 2044 movea.l d4,a0
> > 03298048: 4AA80004 tst.l 4(a0)
> > stop > 0329804C: 66D6 bne.s
> MTWK::__LoadAndRelocate__(unsigned
> > char,_opaque*)+0x1b74 (0x3298024); 0x03298024
> > 0329804E: 4CDF0CF8 movem.l (a7)+,d3-d7/a2-a3
> > 03298052: 4E5E unlk a6
> > 03298054: 4E75 rts
> >
> > Any idea ? Thanks !
> > Chris
> >
> > --
> > For information on using the Palm Developer Forums, or to unsubscribe,
> please see http://www.palmos.com/dev/support/forums/
> >
>
> --
> For information on using the Palm Developer Forums, or to unsubscribe,
please see http://www.palmos.com/dev/support/forums/
>
--
For information on using the Palm Developer Forums, or to unsubscribe, please see
http://www.palmos.com/dev/support/forums/