Skip to content

Commit

Permalink
fix: missed readByte
Browse files Browse the repository at this point in the history
  • Loading branch information
xxCherry committed Aug 8, 2024
1 parent 489aaa1 commit 68c0e99
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/tsprocess/lib/functions.cc
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Napi::Value read_byte(const Napi::CallbackInfo &args) {
}

auto handle = reinterpret_cast<void *>(args[0].As<Napi::Number>().Int64Value());
auto address = args[1].As<Napi::Number>().Int64Value();
auto address = args[1].As<Napi::Number>().Uint32Value();
auto result = memory::read<int8_t>(handle, address);
if (!std::get<1>(result)) {
Napi::TypeError::New(env, logger::format("Couldn't read byte at %x", address)).ThrowAsJavaScriptException();
Expand Down

0 comments on commit 68c0e99

Please sign in to comment.