SLUDGE: Fix Missing Default Switch Cases

These are flagged by GCC if -Wswitch-default is enabled.
This commit is contained in:
D G Turner 2019-12-01 01:08:45 +00:00
parent bffb4418bd
commit ef30ebc0bb
3 changed files with 10 additions and 1 deletions

View File

@ -82,6 +82,8 @@ bool failSecurityCheck(const Common::String &fn) {
case '|':
fatal("Filenames may not contain the following characters: \n\n\\ / : \" < > | ? *\n\nConsequently, the following filename is not allowed:", fn);
return true;
default:
break;
}
}
return false;
@ -123,6 +125,9 @@ static BuiltReturn sayCore(int numParams, LoadedFunction *fun, bool sayIt) {
//debugOut ("BUILTIN: sayCore: %s (%i)\n", newText, p);
fun->isSpeech = true;
return BR_KEEP_AND_PAUSE;
default:
break;
}
fatal("Function should have either 2 or 3 parameters");

View File

@ -182,6 +182,9 @@ Common::String ResourceManager::convertString(const Common::String &s) {
// falls through
case 1:
r = wc + r;
break;
default:
break;
}
res += r;
}

View File

@ -403,7 +403,8 @@ void GraphicsManager::fixBrightness() {
case 6:
transitionSnapshotBox();
break;
default:
break;
}
}