aboutsummaryrefslogtreecommitdiff
path: root/engines/tinsel/debugger.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'engines/tinsel/debugger.cpp')
-rw-r--r--engines/tinsel/debugger.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/engines/tinsel/debugger.cpp b/engines/tinsel/debugger.cpp
index f422c88e94..ed877587c7 100644
--- a/engines/tinsel/debugger.cpp
+++ b/engines/tinsel/debugger.cpp
@@ -57,7 +57,8 @@ int strToInt(const char *s) {
// Hexadecimal string
uint tmp;
- sscanf(s, "%xh", &tmp);
+ if (!sscanf(s, "%xh", &tmp))
+ tmp = 0;
return (int)tmp;
}
@@ -116,7 +117,7 @@ bool Console::cmd_music(int argc, const char **argv) {
int param = strToInt(argv[1]);
if (param == 0) {
- DebugPrintf("Track number/offset can't be 0!\n", argv[0]);
+ DebugPrintf("Track number/offset can't be 0!\n");
} else if (param > 0) {
// Track provided
PlayMidiSequence(GetTrackOffset(param - 1), false);