Skip to content

Commit 4fdb3f4

Browse files
committed
Eval has just one argument
1 parent c95a9ce commit 4fdb3f4

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

ioSystem.ml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -117,11 +117,10 @@ let system (command : string) : bool option Lwt.t =
117117
(fun _ -> Lwt.return None)
118118

119119
(** Run a command controlling the outputs. *)
120-
let eval (command : string) (args : string list)
121-
: ((big_int * string) * string) option Lwt.t =
120+
let eval (command : string list) : ((big_int * string) * string) option Lwt.t =
122121
Lwt.catch (fun _ ->
123-
let args = Array.of_list args in
124-
Lwt_process.with_process_full (command, args) (fun process ->
122+
let command = Array.of_list command in
123+
Lwt_process.with_process_full ("", command) (fun process ->
125124
Lwt.bind (process#status) (fun (status : Unix.process_status) ->
126125
Lwt.bind (Lwt_io.read process#stdout) (fun (output : string) ->
127126
Lwt.bind (Lwt_io.read process#stderr) (fun (error : string) ->

0 commit comments

Comments
 (0)