Bug 912517 - [Message] Crash occuring in MMS when killing the application while the MMS is sending. r=vicamo
author"sasikala.paruchuri" <sasikala.paruchuri@lge.com>
Fri, 06 Sep 2013 19:13:57 +0800
changeset 158783 8c7b45e8adc907f9a81809bbd5190799d58f1775
parent 158782 69ed85dce64b04fc2ffc969038d281dd1aa968ab
child 158784 ffd9e8e157dd50d3aec572adc8a2be658d56da9a
push id2961
push userlsblakk@mozilla.com
push dateMon, 28 Oct 2013 21:59:28 +0000
treeherdermozilla-beta@73ef4f13486f [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersvicamo
bugs912517
milestone26.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 912517 - [Message] Crash occuring in MMS when killing the application while the MMS is sending. r=vicamo Change-Id: I4f91efbd7fdc9f47de8f738b4610ce7f27fa5a92
dom/mobilemessage/src/ipc/SmsParent.cpp
old mode 100644
new mode 100755
--- a/dom/mobilemessage/src/ipc/SmsParent.cpp
+++ b/dom/mobilemessage/src/ipc/SmsParent.cpp
@@ -579,16 +579,18 @@ SmsRequestParent::SendReply(const Messag
   return Send__delete__(this, aReply) ? NS_OK : NS_ERROR_FAILURE;
 }
 
 // nsIMobileMessageCallback
 
 NS_IMETHODIMP
 SmsRequestParent::NotifyMessageSent(nsISupports *aMessage)
 {
+  NS_ENSURE_TRUE(!mActorDestroyed, NS_ERROR_FAILURE);
+
   nsCOMPtr<nsIDOMMozMmsMessage> mms = do_QueryInterface(aMessage);
   if (mms) {
     MmsMessage *msg = static_cast<MmsMessage*>(mms.get());
     ContentParent *parent = static_cast<ContentParent*>(Manager()->Manager());
     MmsMessageData data;
     if (!msg->GetData(parent, data)) {
       return NS_ERROR_FAILURE;
     }
@@ -608,16 +610,18 @@ NS_IMETHODIMP
 SmsRequestParent::NotifySendMessageFailed(int32_t aError)
 {
   return SendReply(ReplyMessageSendFail(aError));
 }
 
 NS_IMETHODIMP
 SmsRequestParent::NotifyMessageGot(nsISupports *aMessage)
 {
+  NS_ENSURE_TRUE(!mActorDestroyed, NS_ERROR_FAILURE);
+
   nsCOMPtr<nsIDOMMozMmsMessage> mms = do_QueryInterface(aMessage);
   if (mms) {
     MmsMessage *msg = static_cast<MmsMessage*>(mms.get());
     ContentParent *parent = static_cast<ContentParent*>(Manager()->Manager());
     MmsMessageData data;
     if (!msg->GetData(parent, data)) {
       return NS_ERROR_FAILURE;
     }