diff options
author | Bartek IwaĆczuk <biwanczuk@gmail.com> | 2024-01-25 23:51:29 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-01-25 23:51:29 +0100 |
commit | 0b0fb94ce2489da642cffd82e0498446d4a1fe1f (patch) | |
tree | af3fd4fd60e0e9fdf5301ac2881b8e5c43f25cbb /runtime/js/40_process.js | |
parent | 7038074c8583465872b16083f54f2211312f0943 (diff) |
fix(fs): instanceof check for Deno.FsFile (#22121)
Regression caused by https://github.com/denoland/deno/pull/22072.
I added a relevant test so we don't regress again.
Fixes https://github.com/denoland/deno/issues/22115
Diffstat (limited to 'runtime/js/40_process.js')
-rw-r--r-- | runtime/js/40_process.js | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/runtime/js/40_process.js b/runtime/js/40_process.js index e6a62dcf7..ea99bcd97 100644 --- a/runtime/js/40_process.js +++ b/runtime/js/40_process.js @@ -21,6 +21,7 @@ const { PromisePrototypeThen, SafePromiseAll, Symbol, + SymbolFor, } = primordials; import { FsFile } from "ext:deno_fs/30_fs.js"; @@ -76,15 +77,21 @@ class Process { this.pid = res.pid; if (res.stdinRid && res.stdinRid > 0) { - this.stdin = new FsFile(res.stdinRid); + this.stdin = new FsFile(res.stdinRid, SymbolFor("Deno.internal.FsFile")); } if (res.stdoutRid && res.stdoutRid > 0) { - this.stdout = new FsFile(res.stdoutRid); + this.stdout = new FsFile( + res.stdoutRid, + SymbolFor("Deno.internal.FsFile"), + ); } if (res.stderrRid && res.stderrRid > 0) { - this.stderr = new FsFile(res.stderrRid); + this.stderr = new FsFile( + res.stderrRid, + SymbolFor("Deno.internal.FsFile"), + ); } } |