> i am very confusing between "MemHandleUNlock" and "MemHandleFree".
> 
> What is the definition to both ?

    MemHandleUnlock() = unlock, not free
    MemHandleFree()   = free :P

  handles need to be locked in order to reference them as a simple
  pointer. you lock a handle using MemHandleLock(). calling 
  MemHandleUnlock() invalidates the pointer that was previously
  obtained via locking. :)

  handles consume space, if you allocated a handle using 
  MemHandleNew() - then, you should clean up after yourself using
  MemHandleFree().

  if you obtained your handle using DmGet1Resource() or similar,
  you cannot free it using MemHandleFree(). you should, by definition
  call DmReleaseResource(), however, i believe, if you look at the
  source code, you'll see this routine does nothing anyhow :P it
  may in future versions of the os.. so, use it :)

  i would suggest you take a look at the memory management sections
  inside the SDK documentation for more detailed explanations.

// az
[EMAIL PROTECTED]
http://www.ardiri.com/    <--- free games!


-- 
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