Bug 792675. Part 2: Change assertion to warning since Web content can trigger it (trying to create URIs relative to a blob URI). r=sicking
authorRobert O'Callahan <robert@ocallahan.org>
Tue, 25 Sep 2012 15:24:43 +1200
changeset 112679 fb9aee660b543fd0fdc2b5a5a1477678492c0064
parent 112678 02a99623c5529ed02025385d67bf7e8aa800571b
child 112680 efdb6f07fd05efb933a4eaed854fbe8f25129eff
push id23835
push userryanvm@gmail.com
push dateFri, 09 Nov 2012 00:52:02 +0000
treeherdermozilla-central@27ae6c86237f [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerssicking
bugs792675
milestone19.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 792675. Part 2: Change assertion to warning since Web content can trigger it (trying to create URIs relative to a blob URI). r=sicking
content/base/src/nsBlobProtocolHandler.cpp
--- a/content/base/src/nsBlobProtocolHandler.cpp
+++ b/content/base/src/nsBlobProtocolHandler.cpp
@@ -64,19 +64,19 @@ nsBlobProtocolHandler::GetFileDataEntryP
   }
 
   return res->mPrincipal;
 }
 
 static FileDataInfo*
 GetFileDataInfo(const nsACString& aUri)
 {
-  NS_ASSERTION(StringBeginsWith(aUri,
-                                NS_LITERAL_CSTRING(BLOBURI_SCHEME ":")),
-               "Bad URI");
+  NS_WARN_IF_FALSE(StringBeginsWith(aUri,
+                                    NS_LITERAL_CSTRING(BLOBURI_SCHEME ":")),
+                   "Bad URI");
 
   if (!gFileDataTable) {
     return nullptr;
   }
 
   FileDataInfo* res;
   gFileDataTable->Get(aUri, &res);
   return res;