From 1ec4068dff686435d1ef0c9a73975f42d6c3b7bf Mon Sep 17 00:00:00 2001 From: midipix Date: Jan 27 2024 05:41:14 +0000 Subject: slbt_split_argv(): following altmode adjustments, ensure argv_get() succeeded. --- diff --git a/src/driver/slbt_driver_ctx.c b/src/driver/slbt_driver_ctx.c index dc68114..c733bfc 100644 --- a/src/driver/slbt_driver_ctx.c +++ b/src/driver/slbt_driver_ctx.c @@ -375,6 +375,15 @@ static int slbt_split_argv( meta = argv_get(argv,optv,ARGV_VERBOSITY_NONE,fderr); } + if (!meta) { + if (flags & SLBT_DRIVER_VERBOSITY_ERRORS) + argv_get( + argv,optv, + slbt_argv_flags(flags), + fderr); + return -1; + } + /* missing all of --mode, --help, --version, --config, --dumpmachine, --features, and --finish? */ mode = help = version = config = finish = features = ccwrap = dumpmachine = aropt = 0;