From c61b5b501561b48b2d9c1037e3dd950f64cf10b7 Mon Sep 17 00:00:00 2001 From: midipix Date: Wed, 9 May 2018 00:28:55 -0400 Subject: driver: -shrext support: only use the extension portion of the extension. --- src/driver/slbt_driver_ctx.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/driver/slbt_driver_ctx.c b/src/driver/slbt_driver_ctx.c index 94e7e9c..9031323 100644 --- a/src/driver/slbt_driver_ctx.c +++ b/src/driver/slbt_driver_ctx.c @@ -644,6 +644,7 @@ static void slbt_init_flavor_settings( { const struct slbt_host_params * host; const struct slbt_flavor_settings * settings; + const char * dot; host = ahost ? ahost : &cctx->host; @@ -670,7 +671,8 @@ static void slbt_init_flavor_settings( memcpy(psettings,settings,sizeof(*settings)); if (cctx->shrext) - psettings->dsosuffix = cctx->shrext; + psettings->dsosuffix = (dot = strrchr(cctx->shrext,'.')) + ? dot : cctx->shrext; } static int slbt_init_ldrpath( -- cgit v1.2.3