mirror of
https://github.com/privacy-scaling-explorations/emp-wasm.git
synced 2026-01-09 10:07:54 -05:00
fix memory getting rewritten before it's received by js
This commit is contained in:
@@ -198,7 +198,7 @@ EM_JS(void, handle_output_bits_raw, (uint8_t* outputBits, int length), {
|
||||
const outputBitsArray = new Uint8Array(Module.HEAPU8.buffer, outputBits, length);
|
||||
|
||||
// Call the JavaScript function with the output bits
|
||||
Module.emp.handleOutput(outputBitsArray);
|
||||
Module.emp.handleOutput(outputBitsArray.slice());
|
||||
});
|
||||
|
||||
EM_JS(void, handle_error, (const char* message), {
|
||||
|
||||
Reference in New Issue
Block a user