From: Timo Sirainen Date: Tue, 6 May 2014 12:34:00 +0000 (+0300) Subject: pop3: Fixed assert-crash with some settings when there are 0 mails. X-Git-Tag: 2.2.13.rc1~38 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d97801ee5fa37b8635ccd0ba798a257969ef1691;p=thirdparty%2Fdovecot%2Fcore.git pop3: Fixed assert-crash with some settings when there are 0 mails. --- diff --git a/src/pop3/pop3-commands.c b/src/pop3/pop3-commands.c index b775428e0c..5bc60ef089 100644 --- a/src/pop3/pop3-commands.c +++ b/src/pop3/pop3-commands.c @@ -838,7 +838,8 @@ cmd_uidl_init(struct client *client, uint32_t seq) struct mail_search_args *search_args; enum mail_fetch_field wanted_fields; - if (client->message_uidls_save && client->message_uidls == NULL) + if (client->message_uidls_save && client->message_uidls == NULL && + client->messages_count > 0) client_uidls_save(client); ctx = i_new(struct cmd_uidl_context, 1);