Mercurial > dovecot > core-2.2
changeset 15260:26236c4e5736
dbox: Log a better error if we have external attachments, but mail_attachment_dir is unset.
author | Timo Sirainen <tss@iki.fi> |
---|---|
date | Fri, 26 Oct 2012 11:12:36 +0300 |
parents | 83cdfd0bc79d |
children | 4d0d3cc20bdb |
files | src/lib-storage/index/dbox-common/dbox-attachment.c |
diffstat | 1 files changed, 7 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/src/lib-storage/index/dbox-common/dbox-attachment.c Fri Oct 26 11:07:43 2012 +0300 +++ b/src/lib-storage/index/dbox-common/dbox-attachment.c Fri Oct 26 11:12:36 2012 +0300 @@ -150,6 +150,13 @@ *error_r = NULL; + if (*file->storage->attachment_dir == '\0') { + mail_storage_set_critical(&file->storage->storage, + "%s contains references to external attachments, " + "but mail_attachment_dir is unset", file->cur_path); + return -1; + } + t_array_init(&extrefs_arr, 16); if (!dbox_attachment_parse_extref_real(ext_refs, pool_datastack_create(), &extrefs_arr)) {