mirror of
https://github.com/libretro/RetroArch
synced 2025-03-29 22:20:21 +00:00
Merge pull request #2949 from FIX94/master
(GX) fixed program crash when no argv structure is present on start
This commit is contained in:
commit
6a7ccdf355
@ -174,6 +174,23 @@ static void frontend_gx_get_environment_settings(
|
||||
#endif
|
||||
#endif
|
||||
|
||||
/* This situation can happen on some loaders so we really need some
|
||||
fake args or else retroarch will just crash on parsing NULL pointers */
|
||||
if(*argc == 0 || argv == NULL)
|
||||
{
|
||||
struct rarch_main_wrap *args = (struct rarch_main_wrap*)params_data;
|
||||
if (args)
|
||||
{
|
||||
args->touched = true;
|
||||
args->no_content = false;
|
||||
args->verbose = false;
|
||||
args->config_path = NULL;
|
||||
args->sram_path = NULL;
|
||||
args->state_path = NULL;
|
||||
args->content_path = NULL;
|
||||
args->libretro_path = NULL;
|
||||
}
|
||||
}
|
||||
#ifdef HW_DOL
|
||||
chdir("carda:/retroarch");
|
||||
#endif
|
||||
|
Loading…
x
Reference in New Issue
Block a user