From: Aki Tuomi Date: Mon, 19 Sep 2016 09:26:08 +0000 (+0300) Subject: fts-backend-lucene: Check that box is not NULL X-Git-Tag: 2.2.26~251 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=ff3bf633ae277fceeb7e3e9b12d0a1064995c31d;p=thirdparty%2Fdovecot%2Fcore.git fts-backend-lucene: Check that box is not NULL fts_backend_update_deinit will set box to NULL and call update_set_mailbox then. --- diff --git a/src/plugins/fts-lucene/fts-backend-lucene.c b/src/plugins/fts-lucene/fts-backend-lucene.c index 3420debe2d..39c5a6dc5c 100644 --- a/src/plugins/fts-lucene/fts-backend-lucene.c +++ b/src/plugins/fts-lucene/fts-backend-lucene.c @@ -310,7 +310,7 @@ fts_backend_lucene_update_set_mailbox(struct fts_backend_update_context *_ctx, fts_index_set_last_uid(ctx->box, ctx->last_uid); ctx->last_uid = 0; } - if (ctx->first_box_vname == NULL) + if (ctx->first_box_vname == NULL && box != NULL) ctx->first_box_vname = i_strdup(box->vname); ctx->box = box; ctx->last_indexed_uid_set = FALSE;