Index: mail/ChangeLog
===================================================================
--- mail/ChangeLog	(revision 35432)
+++ mail/ChangeLog	(working copy)
@@ -1,3 +1,11 @@
+2008-04-29  Bharath Acharya  <abharath@novell.com>
+
+	** Fixes bug #502913
+
+	* em-composer-utils.c: (create_new_composer), (reply_get_composer),
+	(post_reply_to_message): The headers would be set by 
+	e-msg-composer.c:from_changed_cb. So let this function not mess it up.
+
 2008-04-23  Milan Crha  <mcrha@redhat.com>
 
 	** Fix for bug #529375
Index: mail/em-composer-utils.c
===================================================================
--- mail/em-composer-utils.c	(revision 35432)
+++ mail/em-composer-utils.c	(working copy)
@@ -621,11 +621,14 @@
 {
 	EMsgComposer *composer;
 	EAccount *account = NULL;
+	EMsgComposerHdrs* hdrs;
 
 	composer = e_msg_composer_new ();
 	if (composer == NULL)
 		return NULL;
 
+	hdrs = e_msg_composer_get_hdrs (composer);
+
 	if (fromuri)
 		account = mail_config_get_account_by_source_url(fromuri);
 
@@ -636,7 +639,8 @@
 	if (!account)
 		account = e_msg_composer_get_preferred_account (composer);
 
-	e_msg_composer_set_headers (composer, account?account->name:NULL, NULL, NULL, NULL, subject);
+	e_msg_composer_hdrs_set_from_account (hdrs, account?account->name:NULL);
+	e_msg_composer_hdrs_set_subject (hdrs, subject);
 
 	em_composer_utils_setup_default_callbacks (composer);
 
@@ -1403,6 +1407,7 @@
 	const char *message_id, *references;
 	EDestination **tov, **ccv;
 	EMsgComposer *composer;
+	EMsgComposerHdrs* hdrs;
 	char *subject;
 
 	g_return_val_if_fail (CAMEL_IS_MIME_MESSAGE (message), NULL);
@@ -1431,8 +1436,13 @@
 		subject = g_strdup ("");
 	}
 
-	e_msg_composer_set_headers (composer, account ? account->name : NULL, tov, ccv, NULL, subject);
+	hdrs = e_msg_composer_get_hdrs (composer);
 
+	e_msg_composer_hdrs_set_from_account (hdrs, account?account->name:NULL);
+	e_msg_composer_hdrs_set_to (hdrs, tov);
+	e_msg_composer_hdrs_set_cc (hdrs, ccv);
+	e_msg_composer_hdrs_set_subject (hdrs, subject);
+
 	g_free (subject);
 
 	/* add post-to, if nessecary */
@@ -2033,6 +2043,7 @@
 	EDestination **tov = NULL;
 	CamelFolder *real_folder;
 	EMsgComposer *composer;
+	EMsgComposerHdrs* hdrs;
 	char *subject, *url;
 	EAccount *account;
 	char *real_uid;
@@ -2073,8 +2084,12 @@
 	} else {
 		subject = g_strdup ("");
 	}
+	
+	hdrs = e_msg_composer_get_hdrs (composer);
 
-	e_msg_composer_set_headers (composer, account ? account->name : NULL, tov, NULL, NULL, subject);
+	e_msg_composer_hdrs_set_from_account (hdrs, account?account->name:NULL);
+	e_msg_composer_hdrs_set_to (hdrs, tov);
+	e_msg_composer_hdrs_set_subject (hdrs, subject);
 
 	g_free (subject);
 
