@ai-ecoverse/slicc-kernel 1.147.0 → 1.147.3
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 +4 -2
- package/dist/kernel-worker.js.map +2 -2
- package/dist/node-process-worker.js +26 -8
- package/dist/node-process-worker.js.map +3 -3
- package/dist/node.js +4 -2
- package/dist/node.js.map +2 -2
- package/dist/process-worker.js +26 -8
- package/dist/process-worker.js.map +3 -3
- package/dist/types/fs/watch.d.ts +1 -0
- package/dist/types/process/wasi/wasix-linker.d.ts +1 -0
- package/package.json +2 -2
package/dist/process-worker.js
CHANGED
|
@@ -2963,7 +2963,7 @@ var KERNEL_VERSION, OS_RELEASE;
|
|
|
2963
2963
|
var init_version = __esm({
|
|
2964
2964
|
"src/version.ts"() {
|
|
2965
2965
|
"use strict";
|
|
2966
|
-
KERNEL_VERSION = true ? "1.147.
|
|
2966
|
+
KERNEL_VERSION = true ? "1.147.3" : "0.0.0-dev";
|
|
2967
2967
|
OS_RELEASE = "6.0.0-slicc";
|
|
2968
2968
|
}
|
|
2969
2969
|
});
|
|
@@ -12725,13 +12725,15 @@ function directMiss(err, path) {
|
|
|
12725
12725
|
return !path.split("/").some((part) => part === "." || part === "..");
|
|
12726
12726
|
}
|
|
12727
12727
|
function same(fs, path, id) {
|
|
12728
|
+
let st;
|
|
12728
12729
|
try {
|
|
12729
|
-
|
|
12730
|
-
|
|
12731
|
-
|
|
12732
|
-
|
|
12733
|
-
return false;
|
|
12730
|
+
st = fs.stat(path);
|
|
12731
|
+
} catch (err) {
|
|
12732
|
+
if (GONE2.has(err?.code ?? "")) return false;
|
|
12733
|
+
throw err;
|
|
12734
12734
|
}
|
|
12735
|
+
const now = fileIdentity(st.ino, st.mtimeMs);
|
|
12736
|
+
return now === void 0 || now === id;
|
|
12735
12737
|
}
|
|
12736
12738
|
function current(fs, tree, q) {
|
|
12737
12739
|
const to = tree.escapeTo(q);
|
|
@@ -12752,7 +12754,11 @@ function shownLink(fs, tree, q) {
|
|
|
12752
12754
|
const target = tree.readlink(q);
|
|
12753
12755
|
const to = tree.linkTo(q);
|
|
12754
12756
|
if (!to) return target;
|
|
12755
|
-
|
|
12757
|
+
try {
|
|
12758
|
+
return same(fs, to.target, to.id) ? target : `${target} (deleted)`;
|
|
12759
|
+
} catch {
|
|
12760
|
+
return target;
|
|
12761
|
+
}
|
|
12756
12762
|
}
|
|
12757
12763
|
function routing(fs, tree, toProc, shadowing) {
|
|
12758
12764
|
return (p, inner, own, follow3 = true, outside) => {
|
|
@@ -12914,7 +12920,7 @@ function procfsBridge(fs, tree) {
|
|
|
12914
12920
|
get: (target, key, receiver) => key in over ? over[key] : Reflect.get(target, key, receiver)
|
|
12915
12921
|
});
|
|
12916
12922
|
}
|
|
12917
|
-
var DIR_MODE3, FILE_MODE2, LINK_MODE3, PID_NAMES, SYSTEM_NAMES, ProcTree, FOLLOWING, NOT_FOLLOWING, MAX_HOPS2;
|
|
12923
|
+
var DIR_MODE3, FILE_MODE2, LINK_MODE3, PID_NAMES, SYSTEM_NAMES, ProcTree, FOLLOWING, NOT_FOLLOWING, MAX_HOPS2, GONE2;
|
|
12918
12924
|
var init_wasi_procfs = __esm({
|
|
12919
12925
|
"src/process/wasi/wasi-procfs.ts"() {
|
|
12920
12926
|
"use strict";
|
|
@@ -13098,6 +13104,7 @@ var init_wasi_procfs = __esm({
|
|
|
13098
13104
|
FOLLOWING = ["writeFile", "chmod", "utimes", "pwrite", "truncate"];
|
|
13099
13105
|
NOT_FOLLOWING = ["mkdir", "rm", "unlink", "rmdir", "lutimes", "create", "mkfifo"];
|
|
13100
13106
|
MAX_HOPS2 = 40;
|
|
13107
|
+
GONE2 = /* @__PURE__ */ new Set(["ENOENT", "ENOTDIR"]);
|
|
13101
13108
|
}
|
|
13102
13109
|
});
|
|
13103
13110
|
|
|
@@ -14428,9 +14435,20 @@ var init_wasix_linker = __esm({
|
|
|
14428
14435
|
this.publisher?.({ kind: "slot", index: index3, handle, name: name2 });
|
|
14429
14436
|
return index3;
|
|
14430
14437
|
}
|
|
14438
|
+
heapAlloc(bytes) {
|
|
14439
|
+
const exports = this.main?.exports;
|
|
14440
|
+
const calloc = exports?.calloc;
|
|
14441
|
+
if (typeof calloc !== "function") return void 0;
|
|
14442
|
+
const state = exports?.asyncify_get_state;
|
|
14443
|
+
if (typeof state === "function" && state() !== 0) return void 0;
|
|
14444
|
+
const at = calloc(1, bytes) >>> 0;
|
|
14445
|
+
return at === 0 ? void 0 : at;
|
|
14446
|
+
}
|
|
14431
14447
|
allocate(size, alignment) {
|
|
14432
14448
|
if (size === 0) return 0;
|
|
14433
14449
|
const to = Math.max(alignment, 16);
|
|
14450
|
+
const heap = this.heapAlloc(size + to - 16);
|
|
14451
|
+
if (heap !== void 0) return align(heap, to);
|
|
14434
14452
|
const pages2 = Math.ceil((size + (to > PAGE2 ? to : 0)) / PAGE2);
|
|
14435
14453
|
return align(this.memory.grow(pages2) * PAGE2, to);
|
|
14436
14454
|
}
|