LibWasm: Correct memory init size when instantiating

These limits are in units of page size, not bytes.
Also fixes incorrect debug logs.
This commit is contained in:
Ali Mohammad Pur 2021-05-17 21:41:07 +04:30 committed by Ali Mohammad Pur
commit 4a459d2430
Notes: sideshowbarker 2024-07-18 17:23:20 +09:00
3 changed files with 5 additions and 4 deletions

View file

@ -300,7 +300,7 @@ public:
explicit MemoryInstance(const MemoryType& type)
: m_type(type)
{
grow(m_type.limits().min());
grow(m_type.limits().min() * Constants::page_size);
}
auto& type() const { return m_type; }