Wojtek wrote :

> My app runs fine - till HotSync.
> Every launch after HotSync gives "Records left locked in closed unprotected
> DB" when I call DmCloseDatabase.
> I tried to check all records in this DB for dmRecAttrBusy just before
> closing - all records are clear (don't have this attribute set)
> I am wondering what may be the cause.
> Can it be AppInfoBlock?
> I have AppInfoBlock (my own structure) which is read at HotSync.
>
> Apart from this error I get "Chunk over-locked..." after 15 runs starting
> from HotSync. I am not sure what is the corelation between these errors.

I run into the same kind of problem when running my application: POSE keeps
popping up warnings about locked records. Yet, every MemHandleLock is matched
by a MemHandleUnlock and a subsequent DmReleaseRecord or DmReleaseResource (are
these required?). Same for MemLocalIDToLockedPtr calls matched by MemPtrUnlock
when it comes to handling the AppInfoBlock.

This has become counterproductive beyond just popups: when I minimize a Gremlin
crash sequence, the minimizer process often stops at this warning instead of
reaching the orginal crash cause.

I too implemented a loop to find the offending locked record prior to closing
the PDB, to no avail.

Is there an article on code guidelines that can be followed to avoid this
problem?


--
Luc Le Blanc


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

Reply via email to