From: Timo Sirainen Date: Mon, 4 Sep 2017 16:37:12 +0000 (+0300) Subject: pop3-migration: Fail if all IMAP mails were matched by size, but POP3 had extra mails X-Git-Tag: 2.3.0.rc1~1116 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=3bfdab4b3bea87b5c89f31502ef59380afc9e079;p=thirdparty%2Fdovecot%2Fcore.git pop3-migration: Fail if all IMAP mails were matched by size, but POP3 had extra mails This makes the handling same as what happens when the same situation happens and the last mails were matched by headers. That's an error, unless pop3_migration_ignore_*_uidls=yes. --- diff --git a/src/plugins/pop3-migration/pop3-migration-plugin.c b/src/plugins/pop3-migration/pop3-migration-plugin.c index fe18cc1a58..4f5f877f4c 100644 --- a/src/plugins/pop3-migration/pop3-migration-plugin.c +++ b/src/plugins/pop3-migration/pop3-migration-plugin.c @@ -688,7 +688,7 @@ static bool pop3_uidl_assign_by_size(struct mailbox *box) i_debug("pop3_migration: cached uidls=%u, size matches=%u, total=%u", uidl_match, size_match, count); } - return i == count; + return i == count && imap_count == pop3_count; } static int