From 7544f84c4f69edd97eea125d7609f8c61c35eb5f Mon Sep 17 00:00:00 2001 From: "Rob Swindell (on ChromeOS)" <rob@synchro.net> Date: Fri, 17 Feb 2023 20:36:47 -0800 Subject: [PATCH] Fix compile error about label and statements from gcc version 10.2.1 Interestingly, gcc version 12.2 and MSVC 2019 had no problem with this code. --- src/sbbs3/scfg/scfg.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/sbbs3/scfg/scfg.c b/src/sbbs3/scfg/scfg.c index 7b92a3b14c..438b6ce128 100644 --- a/src/sbbs3/scfg/scfg.c +++ b/src/sbbs3/scfg/scfg.c @@ -187,12 +187,14 @@ void cfg_wizard(void) do { switch(stage) { case -1: + { char* opt[] = { "Abort", "Continue", NULL }; wizard_msg(stage, total, "Do you wish to abort the Setup Wizard now?"); if(uifc.list(WIN_SAV | WIN_L2R | WIN_NOBRDR, 0, 10 ,0, NULL, NULL ,"Abort Setup Wizard", opt) == 0) stage = 100; break; + } case __COUNTER__: { char* opt[] = { "Continue", NULL }; @@ -335,8 +337,8 @@ void cfg_wizard(void) "\n" " digital man (rob)\n" ); - char* save_opts[] = { "Save Changes", "Discard Changes", NULL }; - if(uifc.list(WIN_SAV | WIN_L2R | WIN_NOBRDR, 0, 14 ,0, NULL, NULL, NULL, save_opts) != 0) { + char* opts[] = { "Save Changes", "Discard Changes", NULL }; + if(uifc.list(WIN_SAV | WIN_L2R | WIN_NOBRDR, 0, 14 ,0, NULL, NULL, NULL, opts) != 0) { stage = -1; continue; } -- GitLab