Commit a266b4d5 authored by Libretro-Admin's avatar Libretro-Admin
Browse files

use log_cb instead of fprintf

parent 2bfe077a
Pipeline #52937 passed with stages
in 8 minutes and 17 seconds
......@@ -5,7 +5,7 @@
#include "libretro.h"
static retro_log_printf_t log_cb;
retro_log_printf_t log_cb;
void init_log(retro_environment_t environ_cb)
{
......
......@@ -14,6 +14,8 @@
#include "types.h"
#include "main.h"
#include <libretro.h>
#include "flash.h"
#include "race-memory.h"
......@@ -39,6 +41,8 @@ extern int finscan;
extern int language;
extern int tipo_consola;
extern retro_log_printf_t log_cb;
int m_bIsActive;
EMUINFO m_emuInfo;
SYSTEMINFO m_sysInfo[NR_OF_SYSTEMS];
......@@ -168,11 +172,11 @@ static int initRom(void)
return TRUE;
}
fprintf(stderr, "Not a valid or unsupported rom file.\n");
log_cb(RETRO_LOG_ERROR, "Not a valid or unsupported rom file.\n");
return FALSE;
}
fprintf(stderr, "Not a valid or unsupported rom file. romFound==FALSE\n");
log_cb(RETRO_LOG_ERROR, "Not a valid or unsupported rom file. romFound==FALSE\n");
return FALSE;
}
......@@ -231,7 +235,7 @@ int handleInputFile(const char *romName,
romFile = fopen(romName, "rb");
if(!romFile)
{
fprintf(stderr, "Couldn't open %s file\n", romName);
log_cb(RETRO_LOG_ERROR, "Couldn't open %s file\n", romName);
return 0;
}
......@@ -243,7 +247,7 @@ int handleInputFile(const char *romName,
if (!initRom())
{
fprintf(stderr, "initRom couldn't handle %s file\n", romName);
log_cb(RETRO_LOG_ERROR, "initRom couldn't handle %s file\n", romName);
return 0;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment