Re: Patch: fix concurrent accesses to the imap summary
- From: Philip Van Hoof <spam pvanhoof be>
- To: Martin Bonnin <martinbonnin gmail com>
- Cc: tinymail-devel-list <tinymail-devel-list gnome org>
- Subject: Re: Patch: fix concurrent accesses to the imap summary
- Date: Thu, 20 Nov 2008 12:43:54 +0100
ps. A patch that could get approved would be one that locks and unlocks
the summary file with a flock(2) or fcntl(2). Not a hack like this :(
On Thu, 2008-11-20 at 12:40 +0100, Philip Van Hoof wrote:
> Creating two sessions like that is not supported and it's not intended
> that it'll ever be supported. So I can't approve this patch.
>
> Note that the IMAP account already creates a new session by its own, for
> fetching messages. It's not necessary for the client developer to do
> this himself.
>
> Note that this extra session that is internally created is transparent
> for the application developer and should (or will) consume the summary
> correctly already.
>
>
> On Thu, 2008-11-20 at 11:50 +0100, Martin Bonnin wrote:
> > Hello all,
> >
> > Patch is attached. This looks like quite a low-level problem and
> > I'm not sure this patch is enough for all cases. But at least it fixes
> > one instance of the problem (removing on the server then fetching a
> > new message).
> >
> > Changelog:
> > For IMAP, we open 2 sessions: one for standard operations, the other
> > for fetching messages. This makes concurrent accesses to the folder summary
> > therefore corrupting it.
> > This happens e.g when you delete a message and fetch a new one afterwards.
> > This patch adds the "dont_touch_summary" parameter to prevent the
> > GetMsg session to
> > mess up too much.
> >
> > _______________________________________________
> > tinymail-devel-list mailing list
> > tinymail-devel-list gnome org
> > http://mail.gnome.org/mailman/listinfo/tinymail-devel-list
--
Philip Van Hoof, freelance software developer
home: me at pvanhoof dot be
gnome: pvanhoof at gnome dot org
http://pvanhoof.be/blog
http://codeminded.be
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]