Browse Source

* Reget memory when memory is allocated

Michael Van Canneyt 1 year ago
parent
commit
154565601d
1 changed files with 2 additions and 1 deletions
  1. 2 1
      packages/job/src/job_browser.pp

+ 2 - 1
packages/job/src/job_browser.pp

@@ -887,7 +887,8 @@ begin
 
   // allocate wasm memory
   Result:=WasiExports.AllocMem(Len);
-
+  // Need to reget the memory buffer, since it can have changed by the allocmem.
+  view:=getModuleMemoryDataView();
   // write
   p:=Result;
   View.setUint8(p,Args.Length);