From 787b40192a1415d973c04c3a02826db3fa51394f Mon Sep 17 00:00:00 2001 From: midipix Date: Sat, 4 Aug 2018 06:57:53 -0400 Subject: library: removed ntux_create_driver_ctx() [too much of a good thing]. --- src/driver/ntux_driver_ctx.c | 26 -------------------------- 1 file changed, 26 deletions(-) (limited to 'src') diff --git a/src/driver/ntux_driver_ctx.c b/src/driver/ntux_driver_ctx.c index ef3d987..954b2db 100644 --- a/src/driver/ntux_driver_ctx.c +++ b/src/driver/ntux_driver_ctx.c @@ -374,32 +374,6 @@ int ntux_get_driver_ctx( return 0; } -int ntux_create_driver_ctx( - const struct ntux_common_ctx * cctx, - struct ntux_driver_ctx ** pctx) -{ - const struct argv_option * optv[NTUX_OPTV_ELEMENTS]; - struct argv_meta * meta; - struct ntux_driver_ctx_impl * ctx; - char * argv[] = {"ntux_driver",0}; - - if (ntux_init()) - return -1; - - argv_optv_init(ntux_default_options,optv); - - if (!(meta = argv_get(argv,optv,0,STDERR_FILENO))) - return -1; - - if (!(ctx = ntux_driver_ctx_alloc(meta,cctx,0))) - return ntux_get_driver_ctx_fail(0); - - ctx->ctx.cctx = &ctx->cctx; - memcpy(&ctx->cctx,cctx,sizeof(*cctx)); - *pctx = &ctx->ctx; - return NTUX_OK; -} - static void ntux_free_driver_ctx_impl(struct ntux_driver_ctx_alloc * ictx) { argv_free(ictx->meta); -- cgit v1.2.3