From ebeb08156298d721d35375c0a58a7ddd248625f5 Mon Sep 17 00:00:00 2001 From: twinaphex Date: Sun, 11 Sep 2016 19:46:13 +0200 Subject: [PATCH] Rewrite core_load_game --- core_impl.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/core_impl.c b/core_impl.c index ba0b74a848..1a5a9a667a 100644 --- a/core_impl.c +++ b/core_impl.c @@ -255,13 +255,12 @@ bool core_get_memory(retro_ctx_memory_info_t *info) bool core_load_game(retro_ctx_load_content_info_t *load_info) { - if (!load_info) - return false; - - if (load_info->special) + if (load_info && load_info->special) core_game_loaded = core.retro_load_game_special(load_info->special->id, load_info->info, load_info->content->size); + else if (load_info && *load_info->content->elems[0].data) + core_game_loaded = core.retro_load_game(load_info->info); else - core_game_loaded = core.retro_load_game(*load_info->content->elems[0].data ? load_info->info : NULL); + core_game_loaded = core.retro_load_game(NULL); return core_game_loaded; }