@ai-ecoverse/slicc-kernel 1.122.0 → 1.122.2

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.
@@ -3966,6 +3966,7 @@ var init_wasi_host = __esm({
3966
3966
  const { mkfifo } = this.o.fs;
3967
3967
  if (!mkfifo) return E.NOSYS;
3968
3968
  const raw = mem.string(p, l);
3969
+ if (raw === "") throw new WasiError("ENOENT");
3969
3970
  const path = dirfd === AT_FDCWD && !raw.startsWith("/") ? fds.resolve(3, `${this.cwd}/${raw}`) : at(dirfd, p, l);
3970
3971
  const umask = this.o.kernel.call({ op: "proc-umask" });
3971
3972
  const want = mode & 4095 & ~umask;
@@ -5431,7 +5432,7 @@ var KERNEL_VERSION, OS_RELEASE;
5431
5432
  var init_version = __esm({
5432
5433
  "src/version.ts"() {
5433
5434
  "use strict";
5434
- KERNEL_VERSION = true ? "1.122.0" : "0.0.0-dev";
5435
+ KERNEL_VERSION = true ? "1.122.2" : "0.0.0-dev";
5435
5436
  OS_RELEASE = "6.0.0-slicc";
5436
5437
  }
5437
5438
  });
@@ -14271,7 +14272,7 @@ var init_wasi_module = __esm({
14271
14272
  });
14272
14273
 
14273
14274
  // src/process/wasi/wasi-signals.ts
14274
- var DELIVERED_MASK, KERNEL_DEFAULTS, LIBC_DEFAULT_EXIT, SA_RESTART, SA_NOCLDWAIT, DISPOSITION_IGNORE, DISPOSITION_HANDLER, withBit, WASIX_LIBC_DEFAULT_LINE, WasiSignals;
14275
+ var DELIVERED_MASK, KERNEL_DEFAULTS, LIBC_DEFAULT_EXIT, SA_RESTART, SA_NODEFER, SA_NOCLDWAIT, DISPOSITION_IGNORE, DISPOSITION_HANDLER, withBit, WASIX_LIBC_DEFAULT_LINE, WasiSignals;
14275
14276
  var init_wasi_signals = __esm({
14276
14277
  "src/process/wasi/wasi-signals.ts"() {
14277
14278
  "use strict";
@@ -14282,6 +14283,7 @@ var init_wasi_signals = __esm({
14282
14283
  KERNEL_DEFAULTS = [SIG.TSTP, SIG.TTIN, SIG.TTOU, SIG.CHLD, SIG.CONT, SIG.URG, SIG.WINCH].map(sigbit).reduce((m, bit) => m | bit, 0);
14283
14284
  LIBC_DEFAULT_EXIT = 127;
14284
14285
  SA_RESTART = 268435456;
14286
+ SA_NODEFER = 1073741824;
14285
14287
  SA_NOCLDWAIT = 2;
14286
14288
  DISPOSITION_IGNORE = 1;
14287
14289
  DISPOSITION_HANDLER = 2;
@@ -14298,6 +14300,9 @@ var init_wasi_signals = __esm({
14298
14300
  handlers = 0;
14299
14301
  ignoring = 0;
14300
14302
  restarting = 0;
14303
+ nodefer = 0;
14304
+ running = 0;
14305
+ deferred = 0;
14301
14306
  defaults = 0;
14302
14307
  nocldwait = false;
14303
14308
  fallBack;
@@ -14324,6 +14329,7 @@ var init_wasi_signals = __esm({
14324
14329
  this.handlers = withBit(this.handlers, bit, disposition === DISPOSITION_HANDLER);
14325
14330
  this.ignoring = withBit(this.ignoring, bit, disposition === DISPOSITION_IGNORE);
14326
14331
  this.restarting = withBit(this.restarting, bit, (flags & SA_RESTART) !== 0);
14332
+ this.nodefer = withBit(this.nodefer, bit, (flags & SA_NODEFER) !== 0);
14327
14333
  this.defaults = withBit(this.defaults, bit, disposition === 0);
14328
14334
  if (sig === SIG.CHLD) this.nocldwait = (flags & SA_NOCLDWAIT) !== 0;
14329
14335
  return E.SUCCESS;
@@ -14366,6 +14372,22 @@ var init_wasi_signals = __esm({
14366
14372
  if ((this.ignoring & sigbit(sig)) === 0) this.defaultAction(sig);
14367
14373
  return;
14368
14374
  }
14375
+ const bit = sigbit(sig);
14376
+ if ((this.running & bit) !== 0 && (this.nodefer & bit) === 0) {
14377
+ this.deferred |= bit;
14378
+ return;
14379
+ }
14380
+ this.running |= bit;
14381
+ try {
14382
+ this.run(handler, sig);
14383
+ } finally {
14384
+ this.running &= ~bit;
14385
+ }
14386
+ if ((this.deferred & bit) === 0) return;
14387
+ this.deferred &= ~bit;
14388
+ this.raise(sig);
14389
+ }
14390
+ run(handler, sig) {
14369
14391
  const outer = { sig: this.delivering, defaulted: this.defaulted, libc: this.libcDefault };
14370
14392
  this.delivering = sig;
14371
14393
  this.defaulted = false;