@ai-ecoverse/slicc-kernel 1.17.4 → 1.18.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/node.js CHANGED
@@ -6192,6 +6192,7 @@ var WasmProcess = class {
6192
6192
  if (this.exited) return;
6193
6193
  this.exited = true;
6194
6194
  this.clearAlarm();
6195
+ this.interrupt.abort();
6195
6196
  this.options.locks?.release(this.pid);
6196
6197
  this.asyncOps.close();
6197
6198
  for (const pid of this.children.pids()) this.options.onReap?.(pid);
@@ -8027,6 +8028,10 @@ var Launcher = class {
8027
8028
  for (const nodes of this.openFiles) nodes.revoke(at);
8028
8029
  for (const holds of this.held) holds.revoke(at);
8029
8030
  }
8031
+ unmountAll() {
8032
+ const targets = this.mounts.list().map((m) => m.target);
8033
+ for (const target of targets.sort((a, b) => b.length - a.length)) this.umount(target, true);
8034
+ }
8030
8035
  async permit(req) {
8031
8036
  const policy = this.processMounts;
8032
8037
  const allowed = typeof policy === "function" ? await policy(req) : policy;
@@ -8854,6 +8859,7 @@ async function createNodeKernel(options = {}) {
8854
8859
  for (const client of [...clients]) client.detach();
8855
8860
  for (const reject of [...pending]) reject(new Error(TERMINATED));
8856
8861
  for (const kill of [...live]) kill();
8862
+ launcher.unmountAll();
8857
8863
  }
8858
8864
  };
8859
8865
  }