mirror of
https://github.com/libretro/RetroArch
synced 2025-01-29 00:32:49 +00:00
Cleanups
This commit is contained in:
parent
c0c9764afe
commit
3f281bb31f
@ -49,7 +49,7 @@
|
||||
#endif
|
||||
|
||||
static enum frontend_fork ctr_fork_mode = FRONTEND_FORK_NONE;
|
||||
static const char* elf_path_cst = "sdmc:/retroarch/test.3dsx";
|
||||
static const char* elf_path_cst = "sdmc:/retroarch/test.3dsx";
|
||||
|
||||
static void frontend_ctr_get_environment_settings(int *argc, char *argv[],
|
||||
void *args, void *params_data)
|
||||
@ -151,7 +151,7 @@ static void frontend_ctr_exec(const char *path, bool should_load_game)
|
||||
DEBUG_STR(path);
|
||||
|
||||
strlcpy(param.args, elf_path_cst, sizeof(param.args));
|
||||
len = strlen(param.args) + 1;
|
||||
len = strlen(param.args) + 1;
|
||||
param.argc = 1;
|
||||
|
||||
RARCH_LOG("Attempt to load core: [%s].\n", path);
|
||||
@ -172,11 +172,13 @@ static void frontend_ctr_exec(const char *path, bool should_load_game)
|
||||
}
|
||||
else
|
||||
{
|
||||
u32 app_ID_low;
|
||||
char app_ID_str[11];
|
||||
FILE* fp = fopen(path, "rb");
|
||||
u32 app_ID_low = 0;
|
||||
FILE* fp = fopen(path, "rb");
|
||||
size_t bytes_read = fread(app_ID_str, 1, sizeof(app_ID_str), fp);
|
||||
|
||||
fclose(fp);
|
||||
|
||||
if(bytes_read <= 0)
|
||||
{
|
||||
RARCH_LOG("error reading APP_ID from: [%s].\n", path);
|
||||
|
@ -124,8 +124,8 @@ static void dol_copy_argv_path(const char *dolpath, const char *argpath)
|
||||
* heap memory and are restricted to the stack only. */
|
||||
void system_exec_wii(const char *_path, bool should_load_game)
|
||||
{
|
||||
FILE *fp;
|
||||
size_t size, booter_size;
|
||||
FILE *fp = NULL;
|
||||
void *dol = NULL;
|
||||
char path[PATH_MAX_LENGTH] = {0};
|
||||
char game_path[PATH_MAX_LENGTH] = {0};
|
||||
|
@ -188,8 +188,8 @@ static void frontend_wiiu_exec(const char *path, bool should_load_game)
|
||||
u32 argc;
|
||||
char * argv[3];
|
||||
char args[];
|
||||
}*param = getApplicationEndAddr();
|
||||
int len = 0;
|
||||
}*param = getApplicationEndAddr();
|
||||
int len = 0;
|
||||
param->argc = 0;
|
||||
|
||||
if(!path || !*path)
|
||||
@ -395,7 +395,7 @@ static devoptab_t dotab_stdout =
|
||||
};
|
||||
#endif
|
||||
|
||||
void SaveCallback()
|
||||
void SaveCallback(void)
|
||||
{
|
||||
OSSavesDone_ReadyToRelease();
|
||||
}
|
||||
@ -517,7 +517,7 @@ unsigned long _times_r(struct _reent *r, struct tms *tmsbuf)
|
||||
return 0;
|
||||
}
|
||||
|
||||
void __eabi()
|
||||
void __eabi(void)
|
||||
{
|
||||
|
||||
}
|
||||
@ -556,7 +556,7 @@ void someFunc(void *arg)
|
||||
|
||||
static int mcp_hook_fd = -1;
|
||||
|
||||
int MCPHookOpen()
|
||||
int MCPHookOpen(void)
|
||||
{
|
||||
//take over mcp thread
|
||||
mcp_hook_fd = IOS_Open("/dev/mcp", 0);
|
||||
@ -578,7 +578,7 @@ int MCPHookOpen()
|
||||
return 0;
|
||||
}
|
||||
|
||||
void MCPHookClose()
|
||||
void MCPHookClose(void)
|
||||
{
|
||||
if (mcp_hook_fd < 0)
|
||||
return;
|
||||
@ -630,12 +630,14 @@ static void fsdev_exit(void)
|
||||
/* HBL elf entry point */
|
||||
int __entry_menu(int argc, char **argv)
|
||||
{
|
||||
int ret;
|
||||
|
||||
InitFunctionPointers();
|
||||
memoryInitialize();
|
||||
__init();
|
||||
fsdev_init();
|
||||
|
||||
int ret = main(argc, argv);
|
||||
ret = main(argc, argv);
|
||||
|
||||
fsdev_exit();
|
||||
__fini();
|
||||
@ -654,9 +656,11 @@ void _start(int argc, char **argv)
|
||||
|
||||
fsdev_exit();
|
||||
|
||||
/* TODO: fix elf2rpl so it doesn't error with "Could not find matching symbol
|
||||
for relocation" then uncomment this */
|
||||
// __fini();
|
||||
/* TODO: fix elf2rpl so it doesn't error with "Could not find matching symbol
|
||||
for relocation" then uncomment this */
|
||||
#if 0
|
||||
__fini();
|
||||
#endif
|
||||
memoryRelease();
|
||||
SYSRelaunchTitle(0, 0);
|
||||
exit(0);
|
||||
|
Loading…
x
Reference in New Issue
Block a user