[Dovecot] patch to fix binary attachment indexing
FTS indexing of binary attachments is broken in dovecot-2.1.15: the binary data which fts_build_mail_real() sends to fts_build_body_block() (which sends it to fts_backend_update_build_more()) is garbled. This patch ungarbles it but I’m not positive it’s the best fix. --- dovecot-2.1.15/src/plugins/fts/fts-build-mail.c 2012-11-27 02:07:27.000000000 -0600 +++ dovecot/src/plugins/fts/fts-build-mail.c 2013-02-21 19:48:15.000000000 -0600 @@ -178,7 +178,8 @@ *binary_body_r = TRUE; key.type = FTS_BACKEND_BUILD_KEY_BODY_PART_BINARY; } - if (ctx->body_parser == NULL) + if (ctx->body_parser == NULL && + key.type != FTS_BACKEND_BUILD_KEY_BODY_PART_BINARY) ctx->body_parser = fts_parser_text_init(); key.body_content_type = content_type; key.body_content_disposition = ctx->content_disposition;
On 22.2.2013, at 4.06, Mike Abbott michael.abbott@apple.com wrote:
FTS indexing of binary attachments is broken in dovecot-2.1.15: the binary data which fts_build_mail_real() sends to fts_build_body_block() (which sends it to fts_backend_update_build_more()) is garbled. This patch ungarbles it but I’m not positive it’s the best fix.
Applied basically the same logic: http://hg.dovecot.org/dovecot-2.1/rev/b0e68c53771e
I guess you're building a new fts backend?
Applied basically the same logic: http://hg.dovecot.org/dovecot-2.1/rev/b0e68c53771e
Cool, thanks.
I guess you're building a new fts backend?
Just maintaining the one I already have.
participants (2)
-
Mike Abbott
-
Timo Sirainen