瀏覽代碼

Allow working with older emcc versions

phoboslab 6 年之前
父節點
當前提交
7aa9777992
共有 1 個文件被更改,包括 2 次插入0 次删除
  1. 2 0
      src/wasm-module.js

+ 2 - 0
src/wasm-module.js 查看文件

27
 	this.memory = new WebAssembly.Memory({initial: 256});
27
 	this.memory = new WebAssembly.Memory({initial: 256});
28
 	var env = {
28
 	var env = {
29
 		memory: this.memory,
29
 		memory: this.memory,
30
+		memoryBase: 0,
30
 		__memory_base: 0,
31
 		__memory_base: 0,
31
 		table: new WebAssembly.Table({initial: this.moduleInfo.tableSize, element: 'anyfunc'}),
32
 		table: new WebAssembly.Table({initial: this.moduleInfo.tableSize, element: 'anyfunc'}),
33
+		tableBase: 0,
32
 		__table_base: 0,
34
 		__table_base: 0,
33
 		abort: this.c_abort.bind(this),
35
 		abort: this.c_abort.bind(this),
34
 		___assert_fail: this.c_assertFail.bind(this),
36
 		___assert_fail: this.c_assertFail.bind(this),