diff options
-rw-r--r-- | engines/sci/engine/scriptdebug.cpp | 2 | ||||
-rw-r--r-- | engines/sci/engine/vm.cpp | 4 | ||||
-rw-r--r-- | engines/sci/tools.cpp | 2 |
3 files changed, 4 insertions, 4 deletions
diff --git a/engines/sci/engine/scriptdebug.cpp b/engines/sci/engine/scriptdebug.cpp index ab9f088e59..2aee9f9fc4 100644 --- a/engines/sci/engine/scriptdebug.cpp +++ b/engines/sci/engine/scriptdebug.cpp @@ -380,7 +380,7 @@ static void _c_single_seg_info(EngineState *s, mem_obj_t *mobj) { script_t *scr = &(mobj->data.script); sciprintf("script.%03d locked by %d, bufsize=%d (%x)\n", scr->nr, scr->lockers, (uint)scr->buf_size, (uint)scr->buf_size); if (scr->export_table) - sciprintf(" Exports: %4d at %d\n", scr->exports_nr, ((byte *)scr->export_table) - ((byte *)scr->buf)); + sciprintf(" Exports: %4d at %d\n", scr->exports_nr, (int)(((byte *)scr->export_table) - ((byte *)scr->buf))); else sciprintf(" Exports: none\n"); diff --git a/engines/sci/engine/vm.cpp b/engines/sci/engine/vm.cpp index 8f418f0c34..1182d79460 100644 --- a/engines/sci/engine/vm.cpp +++ b/engines/sci/engine/vm.cpp @@ -90,7 +90,7 @@ static inline stack_ptr_t validate_stack_addr(EngineState *s, stack_ptr_t sp) { script_debug_flag = script_error_flag = 1; if (sci_debug_flags & 4) - sciprintf("[VM] Stack index %d out of valid range [%d..%d]\n", sp - s->stack_base, 0, s->stack_top - s->stack_base - 1); + sciprintf("[VM] Stack index %d out of valid range [%d..%d]\n", (int)(sp - s->stack_base), 0, (int)(s->stack_top - s->stack_base - 1)); return 0; } @@ -1462,7 +1462,7 @@ void run_vm(EngineState *s, int restoring) { #ifndef DISABLE_VALIDATIONS if (xs != s->execution_stack + s->execution_stack_pos) { - sciprintf("Error: xs is stale (%d vs %d); last command was %02x\n", xs - s->execution_stack, s->execution_stack_pos, opnumber); + sciprintf("Error: xs is stale (%d vs %d); last command was %02x\n", (int)(xs - s->execution_stack), s->execution_stack_pos, opnumber); } #endif if (script_error_flag) { diff --git a/engines/sci/tools.cpp b/engines/sci/tools.cpp index 4eab6e627f..757190e277 100644 --- a/engines/sci/tools.cpp +++ b/engines/sci/tools.cpp @@ -121,7 +121,7 @@ void _SCIGNUkdebug(const char *funcname, EngineState *s, const char *file, int l else if (area == SCIkWARNING_NR) fprintf(stderr, "%s: Warning ", funcname); else - fprintf(stderr, funcname); + fprintf(stderr, "%s", funcname); fprintf(stderr, "(%s L%d): ", file, line); |