@ai-ecoverse/slicc-kernel 1.124.5 → 1.124.7
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/README.md +1 -1
- package/dist/kernel-worker.js +3 -1
- package/dist/kernel-worker.js.map +2 -2
- package/dist/node-process-worker.js +22 -8
- package/dist/node-process-worker.js.map +2 -2
- package/dist/node.js +3 -1
- package/dist/node.js.map +2 -2
- package/dist/process-worker.js +22 -8
- package/dist/process-worker.js.map +2 -2
- package/dist/types/process/kernel-streams.d.ts +2 -0
- package/package.json +1 -1
|
@@ -5434,7 +5434,7 @@ var KERNEL_VERSION, OS_RELEASE;
|
|
|
5434
5434
|
var init_version = __esm({
|
|
5435
5435
|
"src/version.ts"() {
|
|
5436
5436
|
"use strict";
|
|
5437
|
-
KERNEL_VERSION = true ? "1.124.
|
|
5437
|
+
KERNEL_VERSION = true ? "1.124.7" : "0.0.0-dev";
|
|
5438
5438
|
OS_RELEASE = "6.0.0-slicc";
|
|
5439
5439
|
}
|
|
5440
5440
|
});
|
|
@@ -9368,11 +9368,14 @@ function useZeroDevices(Fs) {
|
|
|
9368
9368
|
mkdev.call(Fs, path, CHAR_DEVICE, dev);
|
|
9369
9369
|
}
|
|
9370
9370
|
}
|
|
9371
|
-
function namesFifo(fs, path) {
|
|
9371
|
+
function namesFifo(fs, path, flags) {
|
|
9372
9372
|
try {
|
|
9373
9373
|
const { node } = fs.lookupPath?.(path, { follow: true }) ?? { node: { mode: 0 } };
|
|
9374
9374
|
return (node.mode & S_IFMT_BITS) === S_IFIFO_BITS;
|
|
9375
|
-
} catch {
|
|
9375
|
+
} catch (err) {
|
|
9376
|
+
const { errno: errno2, code: code2 } = err ?? {};
|
|
9377
|
+
const errnum = typeof errno2 === "number" ? errno2 : wasiErrno(String(code2));
|
|
9378
|
+
if (REFUSED.has(errnum) && (flags & OWN_ERRORS) === 0) throw err;
|
|
9376
9379
|
return false;
|
|
9377
9380
|
}
|
|
9378
9381
|
}
|
|
@@ -9383,7 +9386,7 @@ function useFifoOpens(Fs, attach) {
|
|
|
9383
9386
|
if (typeof open !== "function" || typeof fs.lookupPath !== "function") return;
|
|
9384
9387
|
fs.open = (path, flags, ...rest2) => {
|
|
9385
9388
|
const truncates = typeof path === "string" && typeof flags === "number" && flags & O_TRUNC2;
|
|
9386
|
-
const kept = truncates && namesFifo(fs, path) ? flags & ~O_TRUNC2 : flags;
|
|
9389
|
+
const kept = truncates && namesFifo(fs, path, flags) ? flags & ~O_TRUNC2 : flags;
|
|
9387
9390
|
return open.call(Fs, path, kept, ...rest2);
|
|
9388
9391
|
};
|
|
9389
9392
|
}
|
|
@@ -9698,7 +9701,7 @@ function linuxDevices(Fs) {
|
|
|
9698
9701
|
}
|
|
9699
9702
|
}
|
|
9700
9703
|
}
|
|
9701
|
-
var O_CLOEXEC, FD_CLOEXEC, F_DUPFD, F_GETFD, F_SETFD, F_GETFL, F_DUPFD_CLOEXEC, tracked, IMPORT_NAMES, EBADF, AT_SYMLINK_NOFOLLOW2, EMSCRIPTEN_EPERM, O_PATH2, LITERALS, UTIME_NOW, UTIME_OMIT, PROT_WRITE, MAP_PRIVATE, MAP_TYPE, O_WRONLY5, MAP_ALIGN, DIR_MODE, LINK_MODE, CHAR_DEVICE, O_TRUNC2, S_IFMT_BITS, S_IFIFO_BITS, O_ACCMODE3, O_CREAT, O_EXCL, field, pinnedRoot, rootKind, NAME, AT_FDCWD2, AT_EACCESS2, W_ACCESS, X_ACCESS, AT_SYMLINK_FOLLOW, UTS_FIELD, DEVICE_MODES;
|
|
9704
|
+
var O_CLOEXEC, FD_CLOEXEC, F_DUPFD, F_GETFD, F_SETFD, F_GETFL, F_DUPFD_CLOEXEC, tracked, IMPORT_NAMES, EBADF, AT_SYMLINK_NOFOLLOW2, EMSCRIPTEN_EPERM, O_PATH2, LITERALS, UTIME_NOW, UTIME_OMIT, PROT_WRITE, MAP_PRIVATE, MAP_TYPE, O_WRONLY5, MAP_ALIGN, DIR_MODE, LINK_MODE, CHAR_DEVICE, O_TRUNC2, S_IFMT_BITS, S_IFIFO_BITS, REFUSED, OWN_ERRORS, O_ACCMODE3, O_CREAT, O_EXCL, field, pinnedRoot, rootKind, NAME, AT_FDCWD2, AT_EACCESS2, W_ACCESS, X_ACCESS, AT_SYMLINK_FOLLOW, UTS_FIELD, DEVICE_MODES;
|
|
9702
9705
|
var init_process_fds = __esm({
|
|
9703
9706
|
"src/process/process-fds.ts"() {
|
|
9704
9707
|
"use strict";
|
|
@@ -9760,6 +9763,8 @@ var init_process_fds = __esm({
|
|
|
9760
9763
|
O_TRUNC2 = 512;
|
|
9761
9764
|
S_IFMT_BITS = 61440;
|
|
9762
9765
|
S_IFIFO_BITS = 4096;
|
|
9766
|
+
REFUSED = /* @__PURE__ */ new Set([wasiErrno("EACCES"), wasiErrno("EPERM")]);
|
|
9767
|
+
OWN_ERRORS = 128 | 131072;
|
|
9763
9768
|
O_ACCMODE3 = 3;
|
|
9764
9769
|
O_CREAT = 64;
|
|
9765
9770
|
O_EXCL = 128;
|
|
@@ -12537,15 +12542,23 @@ var init_kernel_streams = __esm({
|
|
|
12537
12542
|
};
|
|
12538
12543
|
}
|
|
12539
12544
|
sizeFromKernel(stream, kfd) {
|
|
12545
|
+
const getattr = this.kernelAttrs(stream, kfd);
|
|
12546
|
+
if (getattr) this.describe(stream, `${stream.path ?? ""}:${++this.described}`, getattr);
|
|
12547
|
+
}
|
|
12548
|
+
fstatFromKernel(stream, kfd) {
|
|
12549
|
+
const getattr = this.kernelAttrs(stream, kfd);
|
|
12550
|
+
if (getattr) stream.stream_ops = { ...stream.stream_ops, getattr };
|
|
12551
|
+
}
|
|
12552
|
+
kernelAttrs(stream, kfd) {
|
|
12540
12553
|
const { size, fdStat: fdStat2 } = this.sys;
|
|
12541
|
-
if (!size) return;
|
|
12554
|
+
if (!size) return void 0;
|
|
12542
12555
|
const node = stream.node;
|
|
12543
|
-
|
|
12556
|
+
return () => {
|
|
12544
12557
|
const base = node.node_ops?.getattr?.(node);
|
|
12545
12558
|
const live = this.call(() => size.call(this.sys, kfd));
|
|
12546
12559
|
const real = fdStat2 && this.call(() => fdStat2.call(this.sys, kfd));
|
|
12547
12560
|
return { ...base, ...real, ...datesOf(real), size: live };
|
|
12548
|
-
}
|
|
12561
|
+
};
|
|
12549
12562
|
}
|
|
12550
12563
|
describe(stream, name2, getattr) {
|
|
12551
12564
|
if (this.descriptions.size === 0) this.useDescriptions();
|
|
@@ -12883,6 +12896,7 @@ function vfsPromoter(Fs, sys, streams2, livePath) {
|
|
|
12883
12896
|
promoted.set(stream.shared, kfd);
|
|
12884
12897
|
}
|
|
12885
12898
|
streams2.attachFile(stream, kfd);
|
|
12899
|
+
streams2.fstatFromKernel(stream, kfd);
|
|
12886
12900
|
};
|
|
12887
12901
|
}
|
|
12888
12902
|
function describeForFork(Fs, sys, streams2, livePath) {
|