Skip to content

Commit

Permalink
lib-imap: imap-bodystructure: Renamed imap_bodystructure_is_plain_7bi…
Browse files Browse the repository at this point in the history
…t() to message_part_data_is_plain_7bit().
  • Loading branch information
stephanbosch authored and GitLab committed Jan 30, 2017
1 parent 946f22a commit afd6338
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/lib-imap/imap-bodystructure.c
Expand Up @@ -473,7 +473,7 @@ static void part_write_body(const struct message_part *part,
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;

Expand Down
6 changes: 3 additions & 3 deletions src/lib-imap/imap-bodystructure.h
Expand Up @@ -32,9 +32,9 @@ void message_part_data_parse_from_header(pool_t pool,
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
Expand Down
2 changes: 1 addition & 1 deletion src/lib-storage/index/index-mail.c
Expand Up @@ -644,7 +644,7 @@ static void index_mail_body_parsed_cache_flags(struct index_mail *mail)
_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
Expand Down

0 comments on commit afd6338

Please sign in to comment.