diff options
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/utils_cmd.c | 12 | ||||
| -rw-r--r-- | lib/utils_cmd.h | 4 |
2 files changed, 8 insertions, 8 deletions
diff --git a/lib/utils_cmd.c b/lib/utils_cmd.c index 42c81793..23d42168 100644 --- a/lib/utils_cmd.c +++ b/lib/utils_cmd.c | |||
| @@ -489,14 +489,14 @@ cmd_run_result cmd_run2(const char *cmd_string, int flags) { | |||
| 489 | cmd_run_result result = { | 489 | cmd_run_result result = { |
| 490 | .cmd_error_code = 0, | 490 | .cmd_error_code = 0, |
| 491 | .error_code = 0, | 491 | .error_code = 0, |
| 492 | .stderr = | 492 | .err = |
| 493 | { | 493 | { |
| 494 | .buf = NULL, | 494 | .buf = NULL, |
| 495 | .buflen = 0, | 495 | .buflen = 0, |
| 496 | .line = NULL, | 496 | .line = NULL, |
| 497 | .lines = 0, | 497 | .lines = 0, |
| 498 | }, | 498 | }, |
| 499 | .stdout = | 499 | .out = |
| 500 | { | 500 | { |
| 501 | .buf = NULL, | 501 | .buf = NULL, |
| 502 | .buflen = 0, | 502 | .buflen = 0, |
| @@ -581,14 +581,14 @@ cmd_run_result cmd_run_array2(char *const *cmd, int flags) { | |||
| 581 | cmd_run_result result = { | 581 | cmd_run_result result = { |
| 582 | .cmd_error_code = 0, | 582 | .cmd_error_code = 0, |
| 583 | .error_code = 0, | 583 | .error_code = 0, |
| 584 | .stderr = | 584 | .err = |
| 585 | { | 585 | { |
| 586 | .buf = NULL, | 586 | .buf = NULL, |
| 587 | .buflen = 0, | 587 | .buflen = 0, |
| 588 | .line = NULL, | 588 | .line = NULL, |
| 589 | .lines = 0, | 589 | .lines = 0, |
| 590 | }, | 590 | }, |
| 591 | .stdout = | 591 | .out = |
| 592 | { | 592 | { |
| 593 | .buf = NULL, | 593 | .buf = NULL, |
| 594 | .buflen = 0, | 594 | .buflen = 0, |
| @@ -610,9 +610,9 @@ cmd_run_result cmd_run_array2(char *const *cmd, int flags) { | |||
| 610 | int pfd_err[2] = {cmd_open_result.stderr_pipe_fd[0], cmd_open_result.stderr_pipe_fd[1]}; | 610 | int pfd_err[2] = {cmd_open_result.stderr_pipe_fd[0], cmd_open_result.stderr_pipe_fd[1]}; |
| 611 | 611 | ||
| 612 | int_cmd_fetch_output2 tmp_stdout = _cmd_fetch_output2(pfd_out[0], flags); | 612 | int_cmd_fetch_output2 tmp_stdout = _cmd_fetch_output2(pfd_out[0], flags); |
| 613 | result.stdout = tmp_stdout.output_container; | 613 | result.out = tmp_stdout.output_container; |
| 614 | int_cmd_fetch_output2 tmp_stderr = _cmd_fetch_output2(pfd_err[0], flags); | 614 | int_cmd_fetch_output2 tmp_stderr = _cmd_fetch_output2(pfd_err[0], flags); |
| 615 | result.stderr = tmp_stderr.output_container; | 615 | result.err = tmp_stderr.output_container; |
| 616 | 616 | ||
| 617 | result.cmd_error_code = _cmd_close(file_descriptor); | 617 | result.cmd_error_code = _cmd_close(file_descriptor); |
| 618 | return result; | 618 | return result; |
diff --git a/lib/utils_cmd.h b/lib/utils_cmd.h index d3a8f14f..04a624b8 100644 --- a/lib/utils_cmd.h +++ b/lib/utils_cmd.h | |||
| @@ -24,8 +24,8 @@ int cmd_file_read(const char *, output *, int); | |||
| 24 | typedef struct { | 24 | typedef struct { |
| 25 | int error_code; | 25 | int error_code; |
| 26 | int cmd_error_code; | 26 | int cmd_error_code; |
| 27 | output stdout; | 27 | output out; |
| 28 | output stderr; | 28 | output err; |
| 29 | } cmd_run_result; | 29 | } cmd_run_result; |
| 30 | cmd_run_result cmd_run2(const char *cmd, int flags); | 30 | cmd_run_result cmd_run2(const char *cmd, int flags); |
| 31 | cmd_run_result cmd_run_array2(char * const *cmd, int flags); | 31 | cmd_run_result cmd_run_array2(char * const *cmd, int flags); |
