aboutsummaryrefslogtreecommitdiff
path: root/common/debugger.cpp
diff options
context:
space:
mode:
authorMax Horn2004-09-04 19:28:30 +0000
committerMax Horn2004-09-04 19:28:30 +0000
commit858153c4f7bfacd8a0f6e8077ccc276fc995eea6 (patch)
tree5d5589a7ebaf31a15af7d86d9bef563654e8df2b /common/debugger.cpp
parent1c94a93a2e0baf0c41ef01bf751593f99f7fa5ca (diff)
downloadscummvm-rg350-858153c4f7bfacd8a0f6e8077ccc276fc995eea6.tar.gz
scummvm-rg350-858153c4f7bfacd8a0f6e8077ccc276fc995eea6.tar.bz2
scummvm-rg350-858153c4f7bfacd8a0f6e8077ccc276fc995eea6.zip
Some type corrections
svn-id: r14896
Diffstat (limited to 'common/debugger.cpp')
-rw-r--r--common/debugger.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/common/debugger.cpp b/common/debugger.cpp
index 900fb03b87..affce062c9 100644
--- a/common/debugger.cpp
+++ b/common/debugger.cpp
@@ -191,8 +191,8 @@ bool Debugger<T>::RunCommand(const char *inputOrig) {
DebugPrintf("byte%s = %d\n", param[0], *(byte *)_dvars[i].variable);
break;
case DVAR_INT:
- *(int *)_dvars[i].variable = atoi(param[1]);
- DebugPrintf("(int)%s = %d\n", param[0], *(int *)_dvars[i].variable);
+ *(int32 *)_dvars[i].variable = atoi(param[1]);
+ DebugPrintf("(int)%s = %d\n", param[0], *(int32 *)_dvars[i].variable);
break;
// Integer Array
case DVAR_INTARRAY: {
@@ -220,19 +220,19 @@ bool Debugger<T>::RunCommand(const char *inputOrig) {
switch(_dvars[i].type) {
// Integer
case DVAR_BYTE:
- DebugPrintf("(byte)%s = %d\n", param[0], *(byte *)_dvars[i].variable);
+ DebugPrintf("(byte)%s = %d\n", param[0], *(const byte *)_dvars[i].variable);
break;
case DVAR_INT:
- DebugPrintf("(int)%s = %d\n", param[0], *(int *)_dvars[i].variable);
+ DebugPrintf("(int)%s = %d\n", param[0], *(const int32 *)_dvars[i].variable);
break;
// Integer array
case DVAR_INTARRAY: {
- char *chr = (char *)strchr(param[0], '[');
+ const char *chr = strchr(param[0], '[');
if (!chr) {
DebugPrintf("You must access this array as %s[element]\n", param[0]);
} else {
int element = atoi(chr+1);
- int32 *var = *(int32 **)_dvars[i].variable;
+ const int32 *var = *(const int32 **)_dvars[i].variable;
if (element >= _dvars[i].optional) {
DebugPrintf("%s is out of range (array is %d elements big)\n", param[0], _dvars[i].optional);
} else {