dovecot-1.2: Don't try to allocate too much memory if extension ...
dovecot at dovecot.org
dovecot at dovecot.org
Wed Sep 10 21:53:16 EEST 2008
details: http://hg.dovecot.org/dovecot-1.2/rev/28abdf929037
changeset: 8185:28abdf929037
user: Timo Sirainen <tss at iki.fi>
date: Wed Sep 10 21:53:13 2008 +0300
description:
Don't try to allocate too much memory if extension intro had too high ext_id.
diffstat:
1 file changed, 5 insertions(+)
src/lib-index/mail-index-sync-ext.c | 5 +++++
diffs (15 lines):
diff -r c22b7db8c173 -r 28abdf929037 src/lib-index/mail-index-sync-ext.c
--- a/src/lib-index/mail-index-sync-ext.c Wed Sep 10 21:46:23 2008 +0300
+++ b/src/lib-index/mail-index-sync-ext.c Wed Sep 10 21:53:13 2008 +0300
@@ -349,6 +349,11 @@ mail_index_sync_ext_unknown_complain(str
uint32_t ext_map_idx)
{
unsigned char *p;
+
+ if (ext_map_idx >= 1024) {
+ /* don't try to track too high values */
+ return TRUE;
+ }
if (ctx->unknown_extensions == NULL) {
ctx->unknown_extensions =
More information about the dovecot-cvs
mailing list