summaryrefslogtreecommitdiffstats
path: root/lib/process/process.h
diff options
context:
space:
mode:
authorJeremy Kerr <jk@ozlabs.org>2014-01-14 15:44:10 +0800
committerJeremy Kerr <jk@ozlabs.org>2014-01-14 15:55:21 +0800
commit33527e065d9506e05f61c020a473544123c0601b (patch)
treee76ef3df4907151438406013a011e69808a8c2c0 /lib/process/process.h
parent4153ab54b5933fc315ad896e264f74571a494c90 (diff)
downloadtalos-petitboot-33527e065d9506e05f61c020a473544123c0601b.tar.gz
talos-petitboot-33527e065d9506e05f61c020a473544123c0601b.zip
lib/process: Add add_stderr flag to process module
For some process execution functions, we'd like to capture stderr as well as stdout. Currently, we unconditionally redirect subprocess stderr to the petitboot log file. This change adds an add_stderr flag to struct process, which indicates to the process library that we want stderr as well as stdout. If this is specified, the subprocess' stderr is captured to stdout_buf. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
Diffstat (limited to 'lib/process/process.h')
-rw-r--r--lib/process/process.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/process/process.h b/lib/process/process.h
index caeda92..ae7fe32 100644
--- a/lib/process/process.h
+++ b/lib/process/process.h
@@ -31,6 +31,7 @@ struct process {
const char *path;
const char **argv;
bool keep_stdout;
+ bool add_stderr;
process_exit_cb exit_cb;
void *data;
OpenPOWER on IntegriCloud