dovecot-1.1: If both byte and message count limits weren't set, ...

dovecot at dovecot.org dovecot at dovecot.org
Fri Mar 7 02:47:03 EET 2008


details:   http://hg.dovecot.org/dovecot-1.1/rev/1b160b2cd080
changeset: 7364:1b160b2cd080
user:      Timo Sirainen <tss at iki.fi>
date:      Fri Mar 07 02:46:57 2008 +0200
description:
If both byte and message count limits weren't set, we recalculated
maildirsize all the time.

diffstat:

1 file changed, 2 insertions(+), 2 deletions(-)
src/plugins/quota/quota-maildir.c |    4 ++--

diffs (14 lines):

diff -r dc24431136b3 -r 1b160b2cd080 src/plugins/quota/quota-maildir.c
--- a/src/plugins/quota/quota-maildir.c	Thu Mar 06 13:15:30 2008 +0200
+++ b/src/plugins/quota/quota-maildir.c	Fri Mar 07 02:46:57 2008 +0200
@@ -433,8 +433,8 @@ static int maildirsize_parse(struct mail
 		return -1;
 	}
 
-	if (total_bytes > rule->bytes_limit ||
-	    total_count > rule->count_limit) {
+	if ((total_bytes > rule->bytes_limit && rule->bytes_limit != 0) ||
+	    (total_count > rule->count_limit && rule->count_limit != 0)) {
 		/* we're over quota. don't trust these values if the file
 		   contains more than the initial summary line, or if the file
 		   is older than 15 minutes. */


More information about the dovecot-cvs mailing list