Kostas Zorbadelos <[EMAIL PROTECTED]> wrote:

> Please discard this question. Our decision in not to use an external
> program (as it will spawn an external process).

OK. Nevertheless, here are the answers:

> > program. I imagine I will do 
> > 
> > - mu_mailbox_create (&mbox,path)
> > - mu_mailbox_open  (mbox, MU_STREAM_RDWR|MU_STREAM_CREAT)
> > - mu_mailbox_get_locker (mbox, &lock)
> > - mu_locker_lock (lock) (at this point my external program will spawn
> > and lock the file using its methods)
> > - do stuff with the mailbox...
> > - mu_locker_unlock (lock) (the external program spawns again)
> > 
> > Am I correct and if so,

Basically you are right, except that you will have to specify default
locker flags before calling mu_mailbox_create using
mu_locker_set_default_flags as mail.local does. 

> > where do I declare the external program and

This is done using mu_locker_set_default_external_program();

> > what arguments is it expected to have?

 -f NUMBER  If a lock already exists, break it if it is older than
            NUMBER seconds
 -r NUMBER  Retry acquiring the lock NUMBER times
 -u         Unlock existing lock

Regards,
Sergey


_______________________________________________
Bug-mailutils mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/bug-mailutils

Reply via email to