mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1084504 - fix Mixed Content Blocking for redirects in e10s. r=mrbkap
This commit is contained in:
parent
3b9c0e23c1
commit
4df1ca192f
@ -19,6 +19,7 @@
|
|||||||
#include "nsIContentViewer.h"
|
#include "nsIContentViewer.h"
|
||||||
#include "nsIChannel.h"
|
#include "nsIChannel.h"
|
||||||
#include "nsIHttpChannel.h"
|
#include "nsIHttpChannel.h"
|
||||||
|
#include "nsIParentChannel.h"
|
||||||
#include "mozilla/Preferences.h"
|
#include "mozilla/Preferences.h"
|
||||||
#include "nsIScriptObjectPrincipal.h"
|
#include "nsIScriptObjectPrincipal.h"
|
||||||
#include "nsISecureBrowserUI.h"
|
#include "nsISecureBrowserUI.h"
|
||||||
@ -214,6 +215,16 @@ nsMixedContentBlocker::AsyncOnChannelRedirect(nsIChannel* aOldChannel,
|
|||||||
return NS_ERROR_FAILURE;
|
return NS_ERROR_FAILURE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// If we are in the parent process in e10s, we don't have access to the
|
||||||
|
// document node, and hence ShouldLoad will fail when we try to get
|
||||||
|
// the docShell. If that's the case, ignore mixed content checks
|
||||||
|
// on redirects in the parent. Let the child check for mixed content.
|
||||||
|
nsCOMPtr<nsIParentChannel> is_ipc_channel;
|
||||||
|
NS_QueryNotificationCallbacks(aNewChannel, is_ipc_channel);
|
||||||
|
if (is_ipc_channel) {
|
||||||
|
return NS_OK;
|
||||||
|
}
|
||||||
|
|
||||||
nsresult rv;
|
nsresult rv;
|
||||||
nsCOMPtr<nsIURI> oldUri;
|
nsCOMPtr<nsIURI> oldUri;
|
||||||
rv = aOldChannel->GetURI(getter_AddRefs(oldUri));
|
rv = aOldChannel->GetURI(getter_AddRefs(oldUri));
|
||||||
|
Loading…
Reference in New Issue
Block a user