@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.
@@ -2553,7 +2553,7 @@ var KERNEL_VERSION, OS_RELEASE;
2553
2553
  var init_version = __esm({
2554
2554
  "src/version.ts"() {
2555
2555
  "use strict";
2556
- KERNEL_VERSION = true ? "1.122.0" : "0.0.0-dev";
2556
+ KERNEL_VERSION = true ? "1.122.2" : "0.0.0-dev";
2557
2557
  OS_RELEASE = "6.0.0-slicc";
2558
2558
  }
2559
2559
  });
@@ -9182,6 +9182,7 @@ var init_wasi_host = __esm({
9182
9182
  const { mkfifo } = this.o.fs;
9183
9183
  if (!mkfifo) return E.NOSYS;
9184
9184
  const raw = mem.string(p, l);
9185
+ if (raw === "") throw new WasiError("ENOENT");
9185
9186
  const path = dirfd === AT_FDCWD2 && !raw.startsWith("/") ? fds.resolve(3, `${this.cwd}/${raw}`) : at(dirfd, p, l);
9186
9187
  const umask = this.o.kernel.call({ op: "proc-umask" });
9187
9188
  const want = mode & 4095 & ~umask;
@@ -11048,7 +11049,7 @@ var init_wasi_procfs = __esm({
11048
11049
  });
11049
11050
 
11050
11051
  // src/process/wasi/wasi-signals.ts
11051
- var DELIVERED_MASK, KERNEL_DEFAULTS, LIBC_DEFAULT_EXIT, SA_RESTART, SA_NOCLDWAIT, DISPOSITION_IGNORE, DISPOSITION_HANDLER, withBit, WASIX_LIBC_DEFAULT_LINE, WasiSignals;
11052
+ var DELIVERED_MASK, KERNEL_DEFAULTS, LIBC_DEFAULT_EXIT, SA_RESTART, SA_NODEFER, SA_NOCLDWAIT, DISPOSITION_IGNORE, DISPOSITION_HANDLER, withBit, WASIX_LIBC_DEFAULT_LINE, WasiSignals;
11052
11053
  var init_wasi_signals = __esm({
11053
11054
  "src/process/wasi/wasi-signals.ts"() {
11054
11055
  "use strict";
@@ -11059,6 +11060,7 @@ var init_wasi_signals = __esm({
11059
11060
  KERNEL_DEFAULTS = [SIG.TSTP, SIG.TTIN, SIG.TTOU, SIG.CHLD, SIG.CONT, SIG.URG, SIG.WINCH].map(sigbit).reduce((m, bit) => m | bit, 0);
11060
11061
  LIBC_DEFAULT_EXIT = 127;
11061
11062
  SA_RESTART = 268435456;
11063
+ SA_NODEFER = 1073741824;
11062
11064
  SA_NOCLDWAIT = 2;
11063
11065
  DISPOSITION_IGNORE = 1;
11064
11066
  DISPOSITION_HANDLER = 2;
@@ -11075,6 +11077,9 @@ var init_wasi_signals = __esm({
11075
11077
  handlers = 0;
11076
11078
  ignoring = 0;
11077
11079
  restarting = 0;
11080
+ nodefer = 0;
11081
+ running = 0;
11082
+ deferred = 0;
11078
11083
  defaults = 0;
11079
11084
  nocldwait = false;
11080
11085
  fallBack;
@@ -11101,6 +11106,7 @@ var init_wasi_signals = __esm({
11101
11106
  this.handlers = withBit(this.handlers, bit, disposition === DISPOSITION_HANDLER);
11102
11107
  this.ignoring = withBit(this.ignoring, bit, disposition === DISPOSITION_IGNORE);
11103
11108
  this.restarting = withBit(this.restarting, bit, (flags & SA_RESTART) !== 0);
11109
+ this.nodefer = withBit(this.nodefer, bit, (flags & SA_NODEFER) !== 0);
11104
11110
  this.defaults = withBit(this.defaults, bit, disposition === 0);
11105
11111
  if (sig === SIG.CHLD) this.nocldwait = (flags & SA_NOCLDWAIT) !== 0;
11106
11112
  return E.SUCCESS;
@@ -11143,6 +11149,22 @@ var init_wasi_signals = __esm({
11143
11149
  if ((this.ignoring & sigbit(sig)) === 0) this.defaultAction(sig);
11144
11150
  return;
11145
11151
  }
11152
+ const bit = sigbit(sig);
11153
+ if ((this.running & bit) !== 0 && (this.nodefer & bit) === 0) {
11154
+ this.deferred |= bit;
11155
+ return;
11156
+ }
11157
+ this.running |= bit;
11158
+ try {
11159
+ this.run(handler, sig);
11160
+ } finally {
11161
+ this.running &= ~bit;
11162
+ }
11163
+ if ((this.deferred & bit) === 0) return;
11164
+ this.deferred &= ~bit;
11165
+ this.raise(sig);
11166
+ }
11167
+ run(handler, sig) {
11146
11168
  const outer = { sig: this.delivering, defaulted: this.defaulted, libc: this.libcDefault };
11147
11169
  this.delivering = sig;
11148
11170
  this.defaulted = false;