Guilherme C. Hazan wrote:
In the Perforce server at PalmSource -- the source for this code and
for the whole glue library have never been released.
Hacks of the world, go get them! :-D
Well, i got it working with this:
FtrPtrNew('SWAB',35,n<<3,(void**)&block);
...
FtrPtrFree('SWAB',35);
plus MemSemaphoreResearve/Release, of course.
best
guich
FtrPtrNew gives you storage memory, MemGluePtrNew should give you
dynamic heap. This is from source of TCPMP player (GPL-ed). You should
rewrite it from scratch since the licence is not compatible with
SuperWaba ;-) BTW, it is good when people honour the licence and share
fully compilable sources ;-)
MemPtr MemGluePtrNew(UInt32 Size)
{
MemPtr p = MemPtrNew(Size);
if (!p)
{
SysAppInfoPtr appInfoP;
UInt16 OwnerID =
SysGetAppInfo(&appInfoP,&appInfoP)->memOwnerID;
p = MemChunkNew(0, Size,(UInt16)(OwnerID |
memNewChunkFlagNonMovable | memNewChunkFlagAllowLarge));
}
return p;
}
--
For information on using the PalmSource Developer Forums, or to unsubscribe,
please see http://www.palmos.com/dev/support/forums/