mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 919209 - Throw re-reports exception onto context. r=bholley
This commit is contained in:
parent
1cf06ad9e1
commit
1f5d2eef71
@ -114,7 +114,16 @@ Throw(JSContext* aCx, nsresult aRv, const char* aMessage)
|
||||
nsresult nr;
|
||||
if (NS_SUCCEEDED(existingException->GetResult(&nr)) &&
|
||||
aRv == nr) {
|
||||
// Just reuse the existing exception.
|
||||
// Reuse the existing exception.
|
||||
|
||||
// Clear pending exception
|
||||
runtime->SetPendingException(nullptr);
|
||||
|
||||
if (!ThrowExceptionObject(aCx, existingException)) {
|
||||
// If we weren't able to throw an exception we're
|
||||
// most likely out of memory
|
||||
JS_ReportOutOfMemory(aCx);
|
||||
}
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user