From: Timo Sirainen Date: Mon, 10 Feb 2020 15:55:13 +0000 (+0200) Subject: lib-index: Change max cache file size from 4 GB to 1 GB X-Git-Tag: 2.3.11.2~608 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=8cda5d280ce01c726c252832ec8760e9e81398d4;p=thirdparty%2Fdovecot%2Fcore.git lib-index: Change max cache file size from 4 GB to 1 GB Over 1 GB sizes already weren't working correctly, because mail_index_uint32_to_offset() assert-crashes on >=1 GB sizes. Fixes: Panic: file mail-index-util.c: line 37 (mail_index_uint32_to_offset): assertion failed: (offset < 0x40000000) --- diff --git a/src/lib-index/mail-index.c b/src/lib-index/mail-index.c index 8f342a40e1..1425ae3810 100644 --- a/src/lib-index/mail-index.c +++ b/src/lib-index/mail-index.c @@ -47,7 +47,7 @@ static const struct mail_index_optimization_settings default_optimization_set = .cache = { .unaccessed_field_drop_secs = 3600 * 24 * 30, .record_max_size = 64 * 1024, - .max_size = (uint32_t)-1, + .max_size = 1024 * 1024 * 1024, .compress_min_size = 32 * 1024, .compress_delete_percentage = 20, .compress_continued_percentage = 200,