soundlib selection in config file wasn't working

When there was more than one option #define'd
selection was not working correctly.
This commit is contained in:
nhmall
2024-12-30 12:54:12 -05:00
parent ac50b7fecc
commit eacfa202d9
3 changed files with 19 additions and 0 deletions

View File

@@ -3741,8 +3741,11 @@ optfn_soundlib(
*/
if ((op = string_for_env_opt(allopt[optidx].name, opts, FALSE))
!= empty_optstr) {
enum soundlib_ids option_id;
get_soundlib_name(soundlibbuf, WINTYPELEN);
option_id = soundlib_id_from_opt(op);
gc.chosen_soundlib = option_id;
assign_soundlib(gc.chosen_soundlib);
} else
return optn_err;