From a2aa37d224a70b2eccc00691d2893e09f107d7cc Mon Sep 17 00:00:00 2001 From: Timo Sirainen Date: Tue, 5 Apr 2011 19:08:31 +0300 Subject: [PATCH] lib-index: Fix to previous check. --- src/lib-index/mail-index-map.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib-index/mail-index-map.c b/src/lib-index/mail-index-map.c index b5b66d62a4..d535016ab4 100644 --- a/src/lib-index/mail-index-map.c +++ b/src/lib-index/mail-index-map.c @@ -169,7 +169,7 @@ mail_index_map_ext_hdr_check_record(const struct mail_index_header *hdr, } /* a large record size is most likely a bug somewhere. the maximum record size is limited to 64k anyway, so try to fail earlier. */ - if (ext_hdr->record_size > sizeof(uint16_t)/2) { + if (ext_hdr->record_size >= 32768) { *error_r = "Record size is too large"; return -1; } -- 2.47.3