From 22f7562e2291c6b8f377c41dd5af797c4bb9df4e Mon Sep 17 00:00:00 2001 From: Alon Zakai Date: Sun, 13 Nov 2016 10:54:02 -0800 Subject: fix table import size when no maximum is provided --- src/wasm/wasm-s-parser.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/wasm/wasm-s-parser.cpp') diff --git a/src/wasm/wasm-s-parser.cpp b/src/wasm/wasm-s-parser.cpp index 5898cc252..3fcb85c6b 100644 --- a/src/wasm/wasm-s-parser.cpp +++ b/src/wasm/wasm-s-parser.cpp @@ -1573,7 +1573,7 @@ void SExpressionWasmBuilder::parseImport(Element& s) { if (j < inner.size() - 1) { wasm.table.max = atoi(inner[j++]->c_str()); } else { - wasm.table.max = wasm.table.initial; + wasm.table.max = Table::kMaxSize; } // ends with the table element type } else if (im->kind == ExternalKind::Memory) { -- cgit v1.2.3