WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
NEW
234971
JSC::JSWebAssemblyModule::createStub() falls through ASSERT_NOT_REACHED()
https://bugs.webkit.org/show_bug.cgi?id=234971
Summary
JSC::JSWebAssemblyModule::createStub() falls through ASSERT_NOT_REACHED()
David Kilzer (:ddkilzer)
Reported
2022-01-07 11:13:57 PST
JSC::JSWebAssemblyModule::createStub() falls through ASSERT_NOT_REACHED(). These fall-throughs should either use RELEASE_ASSERT_NOT_REACHED(), or add a `return nullptr;` statement after ASSERT_NOT_REACHED(). Presumably the switch statement will never fall through unless there is memory corruption, so a RELEASE_ASSERT_NOT_REACHED() would catch such corruption much earlier. JSWebAssemblyModule* JSWebAssemblyModule::createStub(VM& vm, JSGlobalObject* globalObject, Structure* structure, Wasm::Module::ValidationResult&& result) { [...] auto error = module->generateWasmToJSStubs(vm); if (UNLIKELY(!error)) { switch (error.error()) { case Wasm::BindingFailure::OutOfMemory: throwException(globalObject, scope, createJSWebAssemblyLinkError(globalObject, vm, "Out of executable memory"_s)); return nullptr; } ASSERT_NOT_REACHED(); } return module; } See Source/JavaScriptCore/wasm/js/JSWebAssemblyModule.cpp.
Attachments
Add attachment
proposed patch, testcase, etc.
Radar WebKit Bug Importer
Comment 1
2022-01-07 11:14:34 PST
<
rdar://problem/87262829
>
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug