X-Git-Url: https://git.notmuchmail.org/git?a=blobdiff_plain;f=lib%2Fmessage.cc;h=68c020017ea8c87882d11048d3b6e558c302b3df;hb=8a8e2b11c208050aa1d719ec0933f58d51628fdd;hp=b330dcce5ecf374b7f6009ffbbd327fa1d95eaec;hpb=30c475c1ef3d6823ed9ab0affc30328726c5240f;p=notmuch diff --git a/lib/message.cc b/lib/message.cc index b330dcce..68c02001 100644 --- a/lib/message.cc +++ b/lib/message.cc @@ -946,6 +946,14 @@ notmuch_message_get_filenames (notmuch_message_t *message) return _notmuch_filenames_create (message, message->filename_list); } +int +notmuch_message_count_files (notmuch_message_t *message) +{ + _notmuch_message_ensure_filename_list (message); + + return _notmuch_string_list_length (message->filename_list); +} + notmuch_bool_t notmuch_message_get_flag (notmuch_message_t *message, notmuch_message_flag_t flag) @@ -1037,7 +1045,7 @@ _notmuch_message_set_header_values (notmuch_message_t *message, if (date == NULL || *date == '\0') { time_value = 0; } else { - time_value = g_mime_utils_header_decode_date (date, NULL); + time_value = g_mime_utils_header_decode_date_unix (date); /* * Workaround for https://bugzilla.gnome.org/show_bug.cgi?id=779923 */