diff options
Diffstat (limited to 'src/bun.js/node')
-rw-r--r-- | src/bun.js/node/node_fs.zig | 8 | ||||
-rw-r--r-- | src/bun.js/node/syscall.zig | 1 |
2 files changed, 5 insertions, 4 deletions
diff --git a/src/bun.js/node/node_fs.zig b/src/bun.js/node/node_fs.zig index 23596d7b5..ff9f1ba1f 100644 --- a/src/bun.js/node/node_fs.zig +++ b/src/bun.js/node/node_fs.zig @@ -1823,7 +1823,7 @@ const Arguments = struct { .file = undefined, .global_object = ctx.ptr(), }; - var fd: FileDescriptor = std.math.maxInt(FileDescriptor); + var fd: FileDescriptor = JSC.Node.invalid_fd; if (arguments.next()) |arg| { arguments.eat(); @@ -1918,7 +1918,7 @@ const Arguments = struct { } } - if (fd != std.math.maxInt(FileDescriptor)) { + if (fd != JSC.Node.invalid_fd) { stream.file = .{ .fd = fd }; } else if (path) |path_| { stream.file = .{ .path = path_ }; @@ -1957,7 +1957,7 @@ const Arguments = struct { .file = undefined, .global_object = ctx.ptr(), }; - var fd: FileDescriptor = std.math.maxInt(FileDescriptor); + var fd: FileDescriptor = JSC.Node.invalid_fd; if (arguments.next()) |arg| { arguments.eat(); @@ -2044,7 +2044,7 @@ const Arguments = struct { } } - if (fd != std.math.maxInt(FileDescriptor)) { + if (fd != JSC.Node.invalid_fd) { stream.file = .{ .fd = fd }; } else if (path) |path_| { stream.file = .{ .path = path_ }; diff --git a/src/bun.js/node/syscall.zig b/src/bun.js/node/syscall.zig index c2d13ea59..dd961b510 100644 --- a/src/bun.js/node/syscall.zig +++ b/src/bun.js/node/syscall.zig @@ -101,6 +101,7 @@ pub const Tag = enum(u8) { epoll_ctl, kill, waitpid, + posix_spawn, pub var strings = std.EnumMap(Tag, JSC.C.JSStringRef).initFull(null); }; const PathString = @import("../../global.zig").PathString; |