summaryrefslogtreecommitdiffhomepage
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/ntux/ntux.h15
1 files changed, 14 insertions, 1 deletions
diff --git a/include/ntux/ntux.h b/include/ntux/ntux.h
index 07c735b..d43e8ad 100644
--- a/include/ntux/ntux.h
+++ b/include/ntux/ntux.h
@@ -64,6 +64,15 @@ struct ntux_source_version {
const char * commit;
};
+struct ntux_fd_ctx {
+ int fdin;
+ int fdout;
+ int fderr;
+ int fdlog;
+ int fdcwd;
+ int fddst;
+};
+
struct ntux_error_info {
const struct ntux_driver_ctx * edctx;
const struct ntux_unit_ctx * euctx;
@@ -107,17 +116,21 @@ struct ntux_unit_ctx {
/* driver api */
ntux_api int ntux_get_driver_ctx (char **, char **, uint32_t,
+ const struct ntux_fd_ctx *,
struct ntux_driver_ctx **);
ntux_api void ntux_free_driver_ctx (struct ntux_driver_ctx *);
+ntux_api int ntux_get_driver_fdctx (const struct ntux_driver_ctx *, struct ntux_fd_ctx *);
+ntux_api int ntux_set_driver_fdctx (struct ntux_driver_ctx *, const struct ntux_fd_ctx *);
+
/* cmd api */
ntux_api int ntux_cmd_stat (const struct ntux_driver_ctx *, const char *);
ntux_api int ntux_cmd_spawn (const struct ntux_driver_ctx *);
ntux_api int ntux_cmd_strace (const struct ntux_driver_ctx *);
/* utility api */
-ntux_api int ntux_main (int, char **, char **);
+ntux_api int ntux_main (int, char **, char **, const struct ntux_fd_ctx *);
/* error trace api */
ntux_api int ntux_output_error_vector (const struct ntux_driver_ctx *);