Skip to content

Commit ff168ee

Browse files
fixup! Add command parameter to `Process.replace´
1 parent 8cf0c48 commit ff168ee

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/crystal/system/process.cr

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ struct Crystal::System::Process
7777
# def self.spawn(command_args : Args, env : Env?, clear_env : Bool, input : Stdio, output : Stdio, error : Stdio, chdir : Path | String?) : ProcessInformation
7878

7979
# Replaces the current process with a new one.
80-
# def self.replace(command_args : Args, env : Env?, clear_env : Bool, input : Stdio, output : Stdio, error : Stdio, chdir : Path | String?) : NoReturn
80+
# def self.replace(command : String, command_args : Args, env : Env?, clear_env : Bool, input : Stdio, output : Stdio, error : Stdio, chdir : Path | String?) : NoReturn
8181

8282
# Converts a command and array of arguments to the system-specific representation.
8383
# def self.prepare_args(command : String, args : Enumerable(String)?, shell : Bool) : Args

src/crystal/system/win32/process.cr

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -378,8 +378,8 @@ struct Crystal::System::Process
378378
errno
379379
end
380380

381-
def self.replace(command_args, env, clear_env, input, output, error, chdir) : NoReturn
382-
errno = try_replace(command_args, env, clear_env, input, output, error, chdir)
381+
def self.replace(command, command_args, env, clear_env, input, output, error, chdir) : NoReturn
382+
errno = try_replace(command, command_args, env, clear_env, input, output, error, chdir)
383383
raise_exception_from_errno(command_args.is_a?(String) ? command_args : command_args[0], errno)
384384
end
385385

0 commit comments

Comments
 (0)