Bug 582442 - Make unserializable URIs less fatal. r=dougt
authorJosh Matthews <josh@joshmatthews.net>
Tue, 27 Jul 2010 19:40:17 -0700
changeset 48296 f9214514d547d172141f4c5ee4ae975b83b70488
parent 48295 210e4d354aec5c69cbbe9c82ec3b7cf29a779f20
child 48297 9ebd1145c98ae09287bfb80f7b07a24c37d3229b
push id14671
push userdougt@mozilla.com
push dateWed, 28 Jul 2010 16:52:44 +0000
treeherdermozilla-central@da160d0117e7 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersdougt
bugs582442
milestone2.0b3pre
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 582442 - Make unserializable URIs less fatal. r=dougt
netwerk/ipc/NeckoMessageUtils.h
--- a/netwerk/ipc/NeckoMessageUtils.h
+++ b/netwerk/ipc/NeckoMessageUtils.h
@@ -79,19 +79,20 @@ struct ParamTraits<URI>
     WriteParam(aMsg, isNull);
     if (isNull)
       return;
     
     nsCOMPtr<nsIIPCSerializable> serializable = do_QueryInterface(aParam.mURI);
     if (!serializable) {
       nsCString scheme;
       aParam.mURI->GetScheme(scheme);
-      NS_ABORT_IF_FALSE(scheme.EqualsASCII("about:") ||
-                        scheme.EqualsASCII("javascript:"),
-                        "All IPDL URIs must be serializable or an allowed scheme");
+      if (!scheme.EqualsASCII("about:") &&
+          !scheme.EqualsASCII("javascript:") &&
+          !scheme.EqualsASCII("javascript"))
+        NS_WARNING("All IPDL URIs must be serializable or an allowed scheme");
     }
     
     bool isSerialized = !!serializable;
     WriteParam(aMsg, isSerialized);
     if (!isSerialized) {
       nsCString spec, charset;
       aParam.mURI->GetSpec(spec);
       aParam.mURI->GetOriginCharset(charset);