On Wed, Apr 23, 2008 at 11:51:10AM -0400, Henrik Bechmann wrote:
> In Lock($op), I take it that the following statement blocks, ie *waits* 
> until successful, thus effectively creating a queue to write to files? True?
> 
> flock($lockfp,LOCK_EX);

True.

> I want to write a simple counter generator, with counters incrementing 
> in a file, so I need to prevent mult-user concurrent access.

That's the purpose of PmWiki's Lock() function -- it makes certain
that only one PmWiki process has the lock at any one time for operations
that may change the state of the wiki (e.g., editing or saving pages).

Pm

_______________________________________________
pmwiki-users mailing list
[email protected]
http://www.pmichaud.com/mailman/listinfo/pmwiki-users

Reply via email to