mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 866108 - Part 2: Do not assume that we can always get a script global from the context's window; r=padenot
This commit is contained in:
parent
ab2d0bc310
commit
6d602f4c09
@ -350,6 +350,9 @@ AudioContext::GetJSContext() const
|
||||
|
||||
nsCOMPtr<nsIScriptGlobalObject> scriptGlobal =
|
||||
do_QueryInterface(GetParentObject());
|
||||
if (!scriptGlobal) {
|
||||
return nullptr;
|
||||
}
|
||||
nsIScriptContext* scriptContext = scriptGlobal->GetContext();
|
||||
if (!scriptContext) {
|
||||
return nullptr;
|
||||
|
Loading…
Reference in New Issue
Block a user