summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authormidipix <writeonce@midipix.org>2018-08-04 06:03:09 -0400
committermidipix <writeonce@midipix.org>2018-08-04 06:03:09 -0400
commit354314deecd4e4b4bb857bb85f1ece8cd921de97 (patch)
tree9fd3c379d49a4fcef43683380a3c04340da0cf3a /src
parent38c2e75293f1deaefee45f918400c18de5386aa4 (diff)
downloadslibtool-354314deecd4e4b4bb857bb85f1ece8cd921de97.tar.bz2
slibtool-354314deecd4e4b4bb857bb85f1ece8cd921de97.tar.xz
library: removed slbt_create_driver_ctx() [too much of a good thing].
Diffstat (limited to 'src')
-rw-r--r--src/driver/slbt_driver_ctx.c35
1 files changed, 0 insertions, 35 deletions
diff --git a/src/driver/slbt_driver_ctx.c b/src/driver/slbt_driver_ctx.c
index 120f014..eac59c5 100644
--- a/src/driver/slbt_driver_ctx.c
+++ b/src/driver/slbt_driver_ctx.c
@@ -1333,41 +1333,6 @@ int slbt_get_driver_ctx(
return SLBT_OK;
}
-int slbt_create_driver_ctx(
- const struct slbt_common_ctx * cctx,
- const struct slbt_fd_ctx * fdctx,
- struct slbt_driver_ctx ** pctx)
-{
- const struct argv_option * optv[SLBT_OPTV_ELEMENTS];
- struct argv_meta * meta;
- struct slbt_driver_ctx_impl * ctx;
- char * argv[] = {"slibtool_driver",0};
-
- argv_optv_init(slbt_default_options,optv);
-
- if (!fdctx) {
- fdctx = &(const struct slbt_fd_ctx) {
- .fdin = STDIN_FILENO,
- .fdout = STDOUT_FILENO,
- .fderr = STDERR_FILENO,
- .fdlog = (-1),
- .fdcwd = AT_FDCWD,
- .fddst = AT_FDCWD,
- };
- }
-
- if (!(meta = argv_get(argv,optv,0,fdctx->fderr)))
- return -1;
-
- if (!(ctx = slbt_driver_ctx_alloc(meta,fdctx,cctx)))
- return slbt_get_driver_ctx_fail(0);
-
- ctx->ctx.cctx = &ctx->cctx;
- memcpy(&ctx->cctx,cctx,sizeof(*cctx));
- *pctx = &ctx->ctx;
- return SLBT_OK;
-}
-
static void slbt_free_driver_ctx_impl(struct slbt_driver_ctx_alloc * ictx)
{
if (ictx->ctx.targv)