mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-29 04:09:13 +00:00
LibJS: Convert TypedArray::create() to NonnullGCPtr
This commit is contained in:
parent
dd3d133968
commit
37c85fa07e
Notes:
sideshowbarker
2024-07-17 05:02:35 +09:00
Author: https://github.com/linusg
Commit: 37c85fa07e
Pull-request: https://github.com/SerenityOS/serenity/pull/16479
Reviewed-by: https://github.com/davidot ✅
3 changed files with 50 additions and 51 deletions
|
@ -24,7 +24,7 @@ TESTJS_GLOBAL_FUNCTION(read_binary_wasm_file, readBinaryWasmFile)
|
|||
if (file_size.is_error())
|
||||
return vm.throw_completion<JS::TypeError>(strerror(file_size.error().code()));
|
||||
|
||||
auto* array = TRY(JS::Uint8Array::create(realm, file_size.value()));
|
||||
auto array = TRY(JS::Uint8Array::create(realm, file_size.value()));
|
||||
|
||||
auto read = file.value()->read(array->data());
|
||||
if (read.is_error())
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue