diff options
Diffstat (limited to 'engines/sci/engine/vm.cpp')
-rw-r--r-- | engines/sci/engine/vm.cpp | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/engines/sci/engine/vm.cpp b/engines/sci/engine/vm.cpp index 64ee7243fb..943a8e0354 100644 --- a/engines/sci/engine/vm.cpp +++ b/engines/sci/engine/vm.cpp @@ -79,7 +79,7 @@ static StackPtr validate_stack_addr(EngineState *s, StackPtr sp) { if (sp >= s->stack_base && sp < s->stack_top) return sp; - error("[VM] Stack index %d out of valid range [%d..%d]\n", + error("[VM] Stack index %d out of valid range [%d..%d]", (int)(sp - s->stack_base), 0, (int)(s->stack_top - s->stack_base - 1)); return 0; } @@ -87,9 +87,9 @@ static StackPtr validate_stack_addr(EngineState *s, StackPtr sp) { static int validate_arithmetic(reg_t reg) { if (reg.segment) { if (g_debug_weak_validations) - warning("[VM] Attempt to read arithmetic value from non-zero segment [%04x]\n", reg.segment); + warning("[VM] Attempt to read arithmetic value from non-zero segment [%04x]", reg.segment); else - error("[VM] Attempt to read arithmetic value from non-zero segment [%04x]\n", reg.segment); + error("[VM] Attempt to read arithmetic value from non-zero segment [%04x]", reg.segment); return 0; } @@ -99,9 +99,9 @@ static int validate_arithmetic(reg_t reg) { static int signed_validate_arithmetic(reg_t reg) { if (reg.segment) { if (g_debug_weak_validations) - warning("[VM] Attempt to read arithmetic value from non-zero segment [%04x]\n", reg.segment); + warning("[VM] Attempt to read arithmetic value from non-zero segment [%04x]", reg.segment); else - error("[VM] Attempt to read arithmetic value from non-zero segment [%04x]\n", reg.segment); + error("[VM] Attempt to read arithmetic value from non-zero segment [%04x]", reg.segment); return 0; } @@ -214,7 +214,7 @@ ExecStack *execute_method(EngineState *s, uint16 script, uint16 pubfunct, StackP int temp = s->seg_manager->validateExportFunc(pubfunct, seg); if (!temp) { - error("Request for invalid exported function 0x%x of script 0x%x\n", pubfunct, script); + error("Request for invalid exported function 0x%x of script 0x%x", pubfunct, script); return NULL; } @@ -319,7 +319,7 @@ ExecStack *send_selector(EngineState *s, reg_t send_obj, reg_t work_obj, StackPt break; } - error("Send to invalid selector 0x%x of object at %04x:%04x\n", 0xffff & selector, PRINT_REG(send_obj)); + error("Send to invalid selector 0x%x of object at %04x:%04x", 0xffff & selector, PRINT_REG(send_obj)); break; @@ -930,7 +930,7 @@ void run_vm(EngineState *s, int restoring) { } if (opparams[0] >= (int)((SciEngine*)g_engine)->getKernel()->_kernelFuncs.size()) { - error("Invalid kernel function 0x%x requested\n", opparams[0]); + error("Invalid kernel function 0x%x requested", opparams[0]); } else { int argc = ASSERT_ARITHMETIC(scriptState.xs->sp[0]); @@ -941,7 +941,7 @@ void run_vm(EngineState *s, int restoring) { && !kernel_matches_signature(s, ((SciEngine*)g_engine)->getKernel()->_kernelFuncs[opparams[0]].signature, argc, scriptState.xs->sp + 1)) { - error("[VM] Invalid arguments to kernel call %x\n", opparams[0]); + error("[VM] Invalid arguments to kernel call %x", opparams[0]); } else { s->r_acc = ((SciEngine*)g_engine)->getKernel()->_kernelFuncs[opparams[0]].fun(s, opparams[0], argc, scriptState.xs->sp + 1); @@ -1195,7 +1195,7 @@ void run_vm(EngineState *s, int restoring) { #ifndef DISABLE_VALIDATIONS if (r_temp.offset >= code_buf_size) { error("VM: lofss operation overflowed: %04x:%04x beyond end" - " of script (at %04x)\n", PRINT_REG(r_temp), code_buf_size); + " of script (at %04x)", PRINT_REG(r_temp), code_buf_size); } #endif PUSH32(r_temp); @@ -1492,7 +1492,7 @@ SelectorType lookup_selector(EngineState *s, reg_t obj_location, Selector select if (!obj) { - error("lookup_selector(): Error while looking up Species class.\nOriginal address was %04x:%04x. Species address was %04x:%04x\n", + error("lookup_selector(): Error while looking up Species class.\nOriginal address was %04x:%04x. Species address was %04x:%04x", PRINT_REG(obj_location), PRINT_REG(obj->_variables[SCRIPT_SPECIES_SELECTOR])); return kSelectorNone; } |