From 9f900fac321ec0c27162c25aac436c8d7cd64fc9 Mon Sep 17 00:00:00 2001 From: D G Turner Date: Fri, 25 Mar 2022 21:11:33 +0000 Subject: [PATCH] GLK: HUGO: Fix Duplicated Branch GCC Compiler Warning This is emitted if -Wduplicated-branches is passed. --- engines/glk/hugo/herun.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/engines/glk/hugo/herun.cpp b/engines/glk/hugo/herun.cpp index 89902f3104f..31eaac68ea1 100644 --- a/engines/glk/hugo/herun.cpp +++ b/engines/glk/hugo/herun.cpp @@ -1037,9 +1037,14 @@ void Hugo::RunPrint() { { if (!hexnumber) { + // FIXME: This code has identical branch code since the cast to unsigned int of a + // is reversed by passing this to itoa as this has the function signature of: + // char * itoa(int value, char *str, int base) +#if 0 if (capital) itoa((unsigned int)a, line, 10); else +#endif itoa(a, line, 10); capital = 0; }