From 987fb91d5ec4b61d1283acdb9cf02960cc47b74d Mon Sep 17 00:00:00 2001 From: Matthew Barnes Date: Mon, 19 Dec 2011 22:27:39 -0500 Subject: Reduce diff noise with account-mgmt branch. --- mail/e-mail-session.c | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) (limited to 'mail/e-mail-session.c') diff --git a/mail/e-mail-session.c b/mail/e-mail-session.c index 11bdf87b8d..3fb1cb6418 100644 --- a/mail/e-mail-session.c +++ b/mail/e-mail-session.c @@ -1429,6 +1429,8 @@ mail_session_forward_to (CamelSession *session, CamelFolder *out_folder; CamelMessageInfo *info; CamelMedium *medium; + const gchar *from_address; + const gchar *from_name; const gchar *header_name; struct _camel_header_raw *xev; gchar *subject; @@ -1454,6 +1456,9 @@ mail_session_forward_to (CamelSession *session, return FALSE; } + from_address = account->id->address; + from_name = account->id->name; + forward = camel_mime_message_new (); /* make copy of the message, because we are going to modify it */ @@ -1496,8 +1501,7 @@ mail_session_forward_to (CamelSession *session, /* from */ addr = camel_internet_address_new (); - camel_internet_address_add ( - addr, account->id->name, account->id->address); + camel_internet_address_add (addr, from_name, from_address); camel_mime_message_set_from (forward, addr); g_object_unref (addr); @@ -1781,10 +1785,14 @@ static void e_mail_session_init (EMailSession *session) { GSettings *settings; + GHashTable *junk_filters; + + junk_filters = g_hash_table_new ( + (GHashFunc) g_str_hash, + (GEqualFunc) g_str_equal); session->priv = E_MAIL_SESSION_GET_PRIVATE (session); - session->priv->junk_filters = g_hash_table_new ( - (GHashFunc) g_str_hash, (GEqualFunc) g_str_equal); + session->priv->junk_filters = junk_filters; session->priv->proxy = e_proxy_new (); session->priv->local_folders = -- cgit v1.2.3