Hello,

I know that all available documents talk about the limit 64K. But as a
matter of fact there exist apps that managed to work around this limit.

I tried the following:

static MemHandle DmNewResource1(DmOpenRef dbR, UInt32 resType, DmResID
resID, UInt32 size)
{
 MemHandle newH = MemChunkNew(0, size, dmOrphanOwnerID |
memNewChunkFlagAllowLarge);
 Err err = DmAttachResource(dbR, newH, resType, resID);

 MemHandleSetOwner( newH, dmMgrOwnerID ) ;    // dmRecOwnerID  //0
 return newH;
}

Other tested owners are in the comment. The best result I could achieve was
that an application copied this way was working until first reset. ("Free
handle" error message.)
It apparently means that the memory allocation was not persistent.

Can anybody suggest a better alternative?

With best regards,
    Jan Slodicka


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

Reply via email to