[exim-dev] [Bug 1086] wrong return value in maildir_ensure_s…

Page principale
Supprimer ce message
Répondre à ce message
Auteur: Heiko Schlittermann
Date:  
À: exim-dev
Sujet: [exim-dev] [Bug 1086] wrong return value in maildir_ensure_sizefile
------- You are receiving this mail because: -------
You are on the CC list for the bug.

http://bugs.exim.org/show_bug.cgi?id=1086




--- Comment #4 from Heiko Schlittermann <hs+exim@???> 2011-02-21 21:48:48 ---
(In reply to comment #1)

> The appendfile code is written on the basis that after
> maildir_ensure_sizefile() returns != -1, the size and filecount are available.
> The most appropriate solution, other than deferral for this too, seems to be to
> disable quota checks in the event of a race, since the size & count won't have
> been set.


"size" and "count" are set, even we got a race. Thus we should use them for the
quota check. (Under conditions of a heavy flood I'd be happy to see the quota
mechanism kicking in eventually.) It is just the "maildirsize" file what is
deleted since we saw a race during the recalculation process, and we dont want
to leave an inaccurate maildirsize file.


> Another approach would be to also set the size and filecount for the -2 case,
> just nuke the file. I have no strong opinion either way.


That's what the ensure_maildir_size_file() in tf_maildir.c does.

--
Heiko


--
Configure bugmail: http://bugs.exim.org/userprefs.cgi?tab=email