[Scummvm-git-logs] scummvm master -> a2b81f837a28b40665d7f1495e13b4712e4d83da
digitall
547637+digitall at users.noreply.github.com
Thu Nov 11 10:22:50 UTC 2021
This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
a2b81f837a ICB: Fix GCC Identical Branch Compiler Warnings
Commit: a2b81f837a28b40665d7f1495e13b4712e4d83da
https://github.com/scummvm/scummvm/commit/a2b81f837a28b40665d7f1495e13b4712e4d83da
Author: D G Turner (digitall at scummvm.org)
Date: 2021-11-11T10:21:59Z
Commit Message:
ICB: Fix GCC Identical Branch Compiler Warnings
Changed paths:
engines/icb/game_script.cpp
engines/icb/p4_pc.cpp
diff --git a/engines/icb/game_script.cpp b/engines/icb/game_script.cpp
index 4713410fd2..52ee45f9d6 100644
--- a/engines/icb/game_script.cpp
+++ b/engines/icb/game_script.cpp
@@ -84,13 +84,16 @@ void Init_play_movie(const char *param0, bool8 param1);
// runs the gamescript until a given bookmark then returns
// so the pc is set to the correct place for a mission....
void _game_script::Run_to_bookmark(const char *name) {
+ // FIXME: Branches are identical. Dead code or bug?
+#if 0
if ((g_mission) && (g_mission->session)) {
// global
buf = private_session_resman->Res_open(fname, fn_hash, cluster, cluster_hash);
} else {
+#endif
// global
buf = private_session_resman->Res_open(fname, fn_hash, cluster, cluster_hash);
- }
+ //}
char command;
char p1[ENGINE_STRING_LEN];
diff --git a/engines/icb/p4_pc.cpp b/engines/icb/p4_pc.cpp
index 006f1b0ffe..ff436ef6da 100644
--- a/engines/icb/p4_pc.cpp
+++ b/engines/icb/p4_pc.cpp
@@ -287,14 +287,17 @@ bool mainLoopIteration() {
while (g_system->getEventManager()->pollEvent(event)) {
switch (event.type) {
case Common::EVENT_KEYDOWN: {
+ // FIXME: All branches execute effectively the same code
+#if 0
// Pass ENTER and BACKSPACE KEYDOWN events to WriteKey() so the save menu in options_manager_pc.cpp can see them.
if (event.kbd.keycode == Common::KEYCODE_RETURN) {
WriteKey((char)event.kbd.keycode);
} else if (event.kbd.keycode == Common::KEYCODE_BACKSPACE) {
WriteKey((char)event.kbd.keycode);
} else {
+#endif
WriteKey(event.kbd.keycode);
- }
+ //}
setKeyState(event.kbd.keycode, true);
break;
}
More information about the Scummvm-git-logs
mailing list