* refactor: add mu_msg_iter_xapian_get_msg_gmime and use it

This commit is contained in:
Dirk-Jan C. Binnema
2010-08-18 22:49:10 +03:00
parent 145fd8f75c
commit 69c93430b9
3 changed files with 58 additions and 24 deletions

View File

@ -119,16 +119,10 @@ sort_field_from_string (const char* fieldstr)
static void
print_summary (MuMsgIterXapian *iter, size_t summary_len)
{
const char *path, *summ;
const char *summ;
MuMsgGMime *msg;
path = mu_msg_iter_xapian_get_path (iter);
if (!path) {
g_warning ("%s: no path for message", __FUNCTION__);
return;
}
msg = mu_msg_gmime_new (path, NULL);
msg = mu_msg_iter_xapian_get_msg_gmime (iter);
if (!msg) {
g_warning ("%s: failed to create msg object", __FUNCTION__);
return;