aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMilan Crha <mcrha@redhat.com>2010-01-14 02:35:02 +0800
committerMilan Crha <mcrha@redhat.com>2010-01-14 02:35:02 +0800
commit4f94ca687e562281207c3c45ff93f8c09d2c861f (patch)
tree701c7e28605f555420bf3256cfcbc68383b3d62b
parent6ada1ffb628739198927b6a0a9358c2ea9020748 (diff)
downloadgsoc2013-evolution-4f94ca687e562281207c3c45ff93f8c09d2c861f.tar
gsoc2013-evolution-4f94ca687e562281207c3c45ff93f8c09d2c861f.tar.gz
gsoc2013-evolution-4f94ca687e562281207c3c45ff93f8c09d2c861f.tar.bz2
gsoc2013-evolution-4f94ca687e562281207c3c45ff93f8c09d2c861f.tar.lz
gsoc2013-evolution-4f94ca687e562281207c3c45ff93f8c09d2c861f.tar.xz
gsoc2013-evolution-4f94ca687e562281207c3c45ff93f8c09d2c861f.tar.zst
gsoc2013-evolution-4f94ca687e562281207c3c45ff93f8c09d2c861f.zip
Bug #605633 - A little code inconsistency in em_utils_send_receipt
-rw-r--r--mail/em-composer-utils.c14
1 files changed, 6 insertions, 8 deletions
diff --git a/mail/em-composer-utils.c b/mail/em-composer-utils.c
index 371371ac7e..e998c42bf0 100644
--- a/mail/em-composer-utils.c
+++ b/mail/em-composer-utils.c
@@ -1541,6 +1541,9 @@ em_utils_send_receipt (CamelFolder *folder, CamelMimeMessage *message)
if (!receipt_address)
return;
+ /* the 'account' should be always set */
+ g_return_if_fail (account != NULL);
+
/* Collect information for the receipt */
/* We use camel_header_msgid_generate () to get a canonical
@@ -1632,14 +1635,9 @@ em_utils_send_receipt (CamelFolder *folder, CamelMimeMessage *message)
camel_object_unref (addr);
camel_medium_set_header (CAMEL_MEDIUM (receipt), "Return-Path", "<>");
- if (account) {
- camel_medium_set_header (CAMEL_MEDIUM (receipt),
- "X-Evolution-Account", account->uid);
- camel_medium_set_header (CAMEL_MEDIUM (receipt),
- "X-Evolution-Transport", account->transport->url);
- camel_medium_set_header (CAMEL_MEDIUM (receipt),
- "X-Evolution-Fcc", account->sent_folder_uri);
- }
+ camel_medium_set_header (CAMEL_MEDIUM (receipt), "X-Evolution-Account", account->uid);
+ camel_medium_set_header (CAMEL_MEDIUM (receipt), "X-Evolution-Transport", account->transport->url);
+ camel_medium_set_header (CAMEL_MEDIUM (receipt), "X-Evolution-Fcc", account->sent_folder_uri);
/* Send the receipt */
info = camel_message_info_new (NULL);