From 1a25430356bbae41523b2ab1646720b19971efb6 Mon Sep 17 00:00:00 2001 From: Mujtaba Arshad Date: Tue, 25 Oct 2011 11:35:03 -0400 Subject: [PATCH] Bug 694804 - Make attempting to serialize an unserializable object in WyciwycChannelParent a real error. r=michal.novotny --- netwerk/protocol/wyciwyg/WyciwygChannelParent.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/netwerk/protocol/wyciwyg/WyciwygChannelParent.cpp b/netwerk/protocol/wyciwyg/WyciwygChannelParent.cpp index d0c850eeefb..5e898d3f109 100644 --- a/netwerk/protocol/wyciwyg/WyciwygChannelParent.cpp +++ b/netwerk/protocol/wyciwyg/WyciwygChannelParent.cpp @@ -216,8 +216,10 @@ WyciwygChannelParent::OnStartRequest(nsIRequest *aRequest, nsISupports *aContext nsCOMPtr serializable = do_QueryInterface(securityInfo); if (serializable) NS_SerializeToString(serializable, secInfoStr); - else - NS_WARNING("Can't serialize security info"); + else { + NS_ERROR("Can't serialize security info"); + return NS_ERROR_UNEXPECTED; + } } if (mIPCClosed ||