mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-01-26 23:23:33 +00:00
Bug 1448194 - Substract the mBytecodeOffset from the bytecode length, as this could cause some assertion failures. r=mrbkap
This commit is contained in:
parent
563ac19f69
commit
d8df648fc6
@ -1800,7 +1800,8 @@ ScriptLoader::AttemptAsyncScriptCompile(ScriptLoadRequest* aRequest)
|
||||
return NS_ERROR_FAILURE;
|
||||
}
|
||||
} else {
|
||||
if (!JS::CanDecodeOffThread(cx, options, aRequest->mScriptBytecode.length())) {
|
||||
size_t length = aRequest->mScriptBytecode.length() - aRequest->mBytecodeOffset;
|
||||
if (!JS::CanDecodeOffThread(cx, options, length)) {
|
||||
return NS_ERROR_FAILURE;
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user