Add run_external_process_get_output function to get output as well

This commit is contained in:
Marc Di Luzio
2019-02-09 20:11:07 +00:00
parent 392fb221dc
commit e31a811946
3 changed files with 82 additions and 53 deletions

View File

@@ -31,5 +31,10 @@ POSSIBILITY OF SUCH DAMAGE.
#pragma once
#define EXTERNAL_BUFFER_MAX 1024
/* Run an external process and capture the return value */
int run_external_process(const char *const *exec_args);
/* Run an external process and capture the return value as well as output */
int run_external_process_get_output(const char *const *exec_args, char buffer[EXTERNAL_BUFFER_MAX]);