# HG changeset patch # User Stephan Bosch # Date 1477244832 -7200 # Node ID eff89c5ea7387f086822f71e3041336d514b9e25 # Parent 65907879d3d5b2050f42b9e6e73e0a6bdc107648 lib-imap: imap-bodystructure: Renamed imap_bodystructure_is_plain_7bit() to message_part_data_is_plain_7bit(). diff -r 65907879d3d5 -r eff89c5ea738 src/lib-imap/imap-bodystructure.c --- a/src/lib-imap/imap-bodystructure.c Sun Oct 23 19:00:10 2016 +0200 +++ b/src/lib-imap/imap-bodystructure.c Sun Oct 23 19:47:12 2016 +0200 @@ -473,7 +473,7 @@ part_write_bodystructure_common(data, str); } -bool imap_bodystructure_is_plain_7bit(const struct message_part *part) +bool message_part_data_is_plain_7bit(const struct message_part *part) { const struct message_part_data *data = part->data; diff -r 65907879d3d5 -r eff89c5ea738 src/lib-imap/imap-bodystructure.h --- a/src/lib-imap/imap-bodystructure.h Sun Oct 23 19:00:10 2016 +0200 +++ b/src/lib-imap/imap-bodystructure.h Sun Oct 23 19:47:12 2016 +0200 @@ -32,9 +32,9 @@ struct message_part *part, struct message_header_line *hdr); -/* Returns TRUE if BODYSTRUCTURE is - ("text" "plain" ("charset" "us-ascii") NIL NIL "7bit" n n NIL NIL NIL) */ -bool imap_bodystructure_is_plain_7bit(const struct message_part *part) +/* Returns TRUE if this message part has content-type "text/plain", + chaset "us-ascii" and content-tranfer-encoding "7bit" */ +bool message_part_data_is_plain_7bit(const struct message_part *part) ATTR_PURE; /* Write a BODY/BODYSTRUCTURE from given message_part. The message_part->data diff -r 65907879d3d5 -r eff89c5ea738 src/lib-storage/index/index-mail.c --- a/src/lib-storage/index/index-mail.c Sun Oct 23 19:00:10 2016 +0200 +++ b/src/lib-storage/index/index-mail.c Sun Oct 23 19:47:12 2016 +0200 @@ -643,7 +643,7 @@ _mail->seq, cache_flags_idx); if (data->parsed_bodystructure && - imap_bodystructure_is_plain_7bit(data->parts) && + message_part_data_is_plain_7bit(data->parts) && (want_cached || want_plain_bodystructure_cached(mail))) { cache_flags |= MAIL_CACHE_FLAG_TEXT_PLAIN_7BIT_ASCII; /* we need message_parts cached to be able to