summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/sofort/sofort.h15
1 files changed, 14 insertions, 1 deletions
diff --git a/include/sofort/sofort.h b/include/sofort/sofort.h
index 76aeeca..1c1dee2 100644
--- a/include/sofort/sofort.h
+++ b/include/sofort/sofort.h
@@ -70,6 +70,15 @@ struct sfrt_source_version {
const char * commit;
};
+struct sfrt_fd_ctx {
+ int fdin;
+ int fdout;
+ int fderr;
+ int fdlog;
+ int fdcwd;
+ int fddst;
+};
+
struct sfrt_error_info {
const struct sfrt_driver_ctx * edctx;
const struct sfrt_unit_ctx * euctx;
@@ -106,6 +115,7 @@ struct sfrt_unit_ctx {
/* driver api */
sfrt_api int sfrt_get_driver_ctx (char **, char **, uint32_t,
+ const struct sfrt_fd_ctx *,
struct sfrt_driver_ctx **);
sfrt_api void sfrt_free_driver_ctx (struct sfrt_driver_ctx *);
@@ -115,8 +125,11 @@ sfrt_api int sfrt_get_unit_ctx (const struct sfrt_driver_ctx *, const c
sfrt_api void sfrt_free_unit_ctx (struct sfrt_unit_ctx *);
+sfrt_api int sfrt_get_driver_fdctx (const struct sfrt_driver_ctx *, struct sfrt_fd_ctx *);
+sfrt_api int sfrt_set_driver_fdctx (struct sfrt_driver_ctx *, const struct sfrt_fd_ctx *);
+
/* utility api */
-sfrt_api int sfrt_main (int, char **, char **);
+sfrt_api int sfrt_main (int, char **, char **, const struct sfrt_fd_ctx *);
sfrt_api int sfrt_output_dummy (const struct sfrt_common_ctx *, FILE *); /* dummy */
sfrt_api int sfrt_output_name (const struct sfrt_unit_ctx *, FILE *); /* dummy */
sfrt_api int sfrt_output_address (const struct sfrt_unit_ctx *, FILE *); /* dummy */