Bug 1261842 - ContentParent::RecvCreateWindow should always set an nsresult outparam. r?smaug draft
authorMike Conley <mconley@mozilla.com>
Tue, 24 May 2016 15:41:35 -0400
changeset 392001 0aad930dbcf4f91b213bbe91f52ddd95ab6f5710
parent 392000 e566635aae1c8a6d60f61da918029473245c8d08
child 392002 dc2a7edf9b7930259aeeda17db5abfc0099e0a50
push id23919
push usermconley@mozilla.com
push dateFri, 22 Jul 2016 20:54:03 +0000
reviewerssmaug
bugs1261842
milestone50.0a1
Bug 1261842 - ContentParent::RecvCreateWindow should always set an nsresult outparam. r?smaug MozReview-Commit-ID: 79FYAMBIDef
dom/ipc/ContentParent.cpp
--- a/dom/ipc/ContentParent.cpp
+++ b/dom/ipc/ContentParent.cpp
@@ -5291,16 +5291,17 @@ ContentParent::RecvCreateWindow(PBrowser
                                 bool* aWindowIsNew,
                                 InfallibleTArray<FrameScriptInfo>* aFrameScripts,
                                 nsCString* aURLToLoad,
                                 TextureFactoryIdentifier* aTextureFactoryIdentifier,
                                 uint64_t* aLayersId)
 {
   // We always expect to open a new window here. If we don't, it's an error.
   *aWindowIsNew = true;
+  *aResult = NS_OK;
 
   // The content process should never be in charge of computing whether or
   // not a window should be private or remote - the parent will do that.
   const uint32_t badFlags =
         nsIWebBrowserChrome::CHROME_PRIVATE_WINDOW
       | nsIWebBrowserChrome::CHROME_NON_PRIVATE_WINDOW
       | nsIWebBrowserChrome::CHROME_PRIVATE_LIFETIME
       | nsIWebBrowserChrome::CHROME_REMOTE_WINDOW;