Replace printf/fprintf with own print_info() / print_error() using SDL_log
[mercenary-reloaded.git] / src / mercenary / mercenary2.c
index 65e970e..37d648a 100644 (file)
@@ -20,6 +20,7 @@
 #include <stdio.h>
 #include <stdint.h>
 #include <stdlib.h>
+#include "../libsdl/print.h"
 #include "../libcpu/m68k.h"
 #include "../libcpu/execute.h"
 #include "mercenary.h"
@@ -64,13 +65,13 @@ void mercenary_patch(void)
 
        /* reduce loop that waits for disk stepper to move */
        if (m68k_read_memory_32(0x55398) != 0x0000091b) {
-               fprintf(stderr, "expecting loop counter of 0x0000091b here, please fix!\n");
+               print_error("expecting loop counter of 0x0000091b here, please fix!\n");
                exit(0);
        }
        m68k_write_memory_32(0x55398, 1);
        /* reduce loop that waits for disk side change */
        if (m68k_read_memory_32(0x54ffc) != 0x00000d02) {
-               fprintf(stderr, "expecting loop counter of 0x00000d02 here, please fix!\n");
+               print_error("expecting loop counter of 0x00000d02 here, please fix!\n");
                exit(0);
        }
        m68k_write_memory_32(0x54ffc, 1);