Index: src/wasm/module-decoder.cc |
diff --git a/src/wasm/module-decoder.cc b/src/wasm/module-decoder.cc |
index eb3766ba6579c47c7f513f86041fe6e3121efa80..d3c08bde527028a6c9ac5a742d0571b05aae2d98 100644 |
--- a/src/wasm/module-decoder.cc |
+++ b/src/wasm/module-decoder.cc |
@@ -322,7 +322,7 @@ class ModuleDecoder : public Decoder { |
// ===== Imported memory ========================================= |
if (!AddMemory(module)) break; |
consume_resizable_limits( |
- "memory", "pages", kV8MaxWasmMemoryPages, |
+ "memory", "pages", FLAG_wasm_max_mem_pages, |
&module->min_mem_pages, &module->has_max_mem, |
kSpecMaxWasmMemoryPages, &module->max_mem_pages); |
break; |
@@ -394,7 +394,7 @@ class ModuleDecoder : public Decoder { |
for (uint32_t i = 0; ok() && i < memory_count; i++) { |
if (!AddMemory(module)) break; |
- consume_resizable_limits("memory", "pages", kV8MaxWasmMemoryPages, |
+ consume_resizable_limits("memory", "pages", FLAG_wasm_max_mem_pages, |
&module->min_mem_pages, &module->has_max_mem, |
kSpecMaxWasmMemoryPages, |
&module->max_mem_pages); |