fix issue sending inline images when e-mail address of identity has whitespace, r=neil, bug 685462
authorDavid Bienvenu <bienvenu@nventure.com>
Mon, 19 Sep 2011 07:32:03 -0700
changeset 9202 fbb0e1b6ad17842cfdc98999c59ec8bbdbf3ad40
parent 9201 ef89418b60de5c42481683c92b09083af6475020
child 9203 02df7fdfbf98bbda76b95e74cbc03b93c90933a8
push id230
push userbugzilla@standard8.plus.com
push dateTue, 08 Nov 2011 22:55:24 +0000
treeherdercomm-beta@63dad5648415 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersneil, bug
bugs685462
fix issue sending inline images when e-mail address of identity has whitespace, r=neil, bug 685462
mailnews/compose/src/nsMsgSend.cpp
--- a/mailnews/compose/src/nsMsgSend.cpp
+++ b/mailnews/compose/src/nsMsgSend.cpp
@@ -1974,16 +1974,17 @@ nsMsgComposeAndSend::ProcessMultipartRel
       if (m_attachments[i].mURL)
         msg_pick_real_name(&m_attachments[i], nsnull, mCompFields->GetCharacterSet());
 
       //
       // Next, generate a content id for use with this part
       //
       nsCString email;
       mUserIdentity->GetEmail(email);
+      email.StripWhitespace();
       m_attachments[i].m_content_id = mime_gen_content_id(locCount+1, email.get());
 
       if (!m_attachments[i].m_content_id)
         return NS_ERROR_OUT_OF_MEMORY;
 
       //
       // Start counting the attachments which are going to come from mail folders
       // and from NNTP servers.