diff options
Diffstat (limited to 'src/js')
-rw-r--r-- | src/js/wasm.js-post.js | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/js/wasm.js-post.js b/src/js/wasm.js-post.js index d691c22f2..1c5e6b0b1 100644 --- a/src/js/wasm.js-post.js +++ b/src/js/wasm.js-post.js @@ -212,8 +212,11 @@ function integrateWasmJS(Module) { info.global = global; info.env = env; - if (!('memInitBase' in env)) { - env['memInitBase'] = STATIC_BASE; // tell the memory segments where to place themselves + if (!('memoryBase' in env)) { + env['memoryBase'] = STATIC_BASE; // tell the memory segments where to place themselves + } + if (!('tableBase' in env)) { + env['tableBase'] = 0; // tell the memory segments where to place themselves } wasmJS['providedTotalMemory'] = Module['buffer'].byteLength; |