aboutsummaryrefslogtreecommitdiff
path: root/engines/glk
diff options
context:
space:
mode:
authorD G Turner2019-12-16 04:49:17 +0000
committerD G Turner2019-12-16 04:49:17 +0000
commit2d08e945216e5bf1b83069dd8cc1c163c49ba68d (patch)
tree3f90b7e7611a6c445b65ad1f0f491ddbebdaef8e /engines/glk
parentf13ea97bad855298590d93297a0eb9f3c420b5ef (diff)
downloadscummvm-rg350-2d08e945216e5bf1b83069dd8cc1c163c49ba68d.tar.gz
scummvm-rg350-2d08e945216e5bf1b83069dd8cc1c163c49ba68d.tar.bz2
scummvm-rg350-2d08e945216e5bf1b83069dd8cc1c163c49ba68d.zip
GLK: MAGNETIC: Fix Missing Default Switch Cases
These are flagged by GCC if -Wswitch-default is enabled.
Diffstat (limited to 'engines/glk')
-rw-r--r--engines/glk/magnetic/emu.cpp27
-rw-r--r--engines/glk/magnetic/glk.cpp1
2 files changed, 26 insertions, 2 deletions
diff --git a/engines/glk/magnetic/emu.cpp b/engines/glk/magnetic/emu.cpp
index 80682d546d..1c92054642 100644
--- a/engines/glk/magnetic/emu.cpp
+++ b/engines/glk/magnetic/emu.cpp
@@ -1298,8 +1298,10 @@ void Magnetic::set_arg1() {
#ifdef LOGEMU
out(" %X(a%.1d)", i, regnr);
#endif
- }
- break;
+ }
+ break;
+ default:
+ break;
case 6:
tmp[0] = byte1;
tmp[1] = byte2;
@@ -1375,6 +1377,8 @@ void Magnetic::set_arg1() {
out(" #%.4X", arg1i);
#endif
break;
+ default:
+ break;
}
break;
}
@@ -1456,6 +1460,8 @@ void Magnetic::set_flags() {
if ((j >> 31) > 0)
nflag = 0xff;
break;
+ default:
+ break;
}
}
@@ -1491,6 +1497,8 @@ int Magnetic::condition(type8 b) {
return (zflag | nflag) ^ 0xff;
case 15:
return (zflag | nflag);
+ default:
+ break;
}
return 0x00;
}
@@ -2067,6 +2075,8 @@ type16s Magnetic::hint_input() {
return -3; /* Next hint */
case 'p':
return -4; /* Show parent hint list */
+ default:
+ break;
}
}
return 0;
@@ -2138,10 +2148,15 @@ type16 Magnetic::show_hints_text(ms_hint *hintsData, type16 index) {
break;
case -4: /* Show parent hint list */
return 0;
+ default:
+ break;
}
} else
return 0;
break;
+
+ default:
+ break;
}
}
return 0;
@@ -2215,6 +2230,8 @@ void Magnetic::do_line_a() {
case 3: /* Compass */
output_text(not_supported);
break;
+ default:
+ break;
}
break;
@@ -2237,6 +2254,9 @@ void Magnetic::do_line_a() {
break;
}
break;
+
+ default:
+ break;
}
break;
@@ -2518,6 +2538,9 @@ void Magnetic::do_line_a() {
case 34: /* Dictionary_lookup A0FF */
dict_lookup();
break;
+
+ default:
+ break;
}
}
diff --git a/engines/glk/magnetic/glk.cpp b/engines/glk/magnetic/glk.cpp
index 3ab3fdb5e0..68a7a3e692 100644
--- a/engines/glk/magnetic/glk.cpp
+++ b/engines/glk/magnetic/glk.cpp
@@ -2954,6 +2954,7 @@ void Magnetic::gms_command_gamma(const char *argument) {
gms_normal_string("Glk automatic gamma correction mode is '");
switch (gms_gamma_mode) {
case GAMMA_OFF:
+ default:
gms_normal_string("off");
break;
case GAMMA_NORMAL: