Co-authored-by: Jarred Sumner <jarred@jarredsumner.com>
This commit is contained in:
dave caruso
2024-02-05 10:06:23 -08:00
committed by GitHub
parent bd4d0d15db
commit 48ed1dfb65
4 changed files with 33 additions and 7 deletions

View File

@@ -348,7 +348,7 @@ pub const RunCommand = struct {
child_process.stdout_behavior = .Inherit;
if (Environment.isWindows) {
try @import("../child_process_windows.zig").spawnWindows(&child_process);
try bun.WindowsSpawnWorkaround.spawnWindows(&child_process);
} else {
try child_process.spawn();
}
@@ -434,7 +434,13 @@ pub const RunCommand = struct {
child_process.stdout_behavior = .Inherit;
const silent = ctx.debug.silent;
const result = child_process.spawnAndWait() catch |err| {
if (Environment.isWindows) {
try bun.WindowsSpawnWorkaround.spawnWindows(&child_process);
} else {
try child_process.spawn();
}
const result = child_process.wait() catch |err| {
if (err == error.AccessDenied) {
if (comptime Environment.isPosix) {
var stat = std.mem.zeroes(std.c.Stat);