Add early return to RARCH_CMD_HISTORY_INIT

This commit is contained in:
twinaphex 2014-11-27 08:58:31 +01:00
parent df8e3dfc55
commit 678460b5c1
2 changed files with 3 additions and 2 deletions

View File

@ -252,10 +252,9 @@ returntype main_entry(signature())
}
}
rarch_main_command(RARCH_CMD_HISTORY_INIT);
if (g_settings.history_list_enable)
{
rarch_main_command(RARCH_CMD_HISTORY_INIT);
if (g_extern.content_is_init || g_extern.system.no_content)
history_playlist_push(g_defaults.history,
g_extern.fullpath,

View File

@ -2413,6 +2413,8 @@ bool rarch_main_command(unsigned cmd)
break;
case RARCH_CMD_HISTORY_INIT:
rarch_main_command(RARCH_CMD_HISTORY_DEINIT);
if (!g_settings.history_list_enable)
return false;
g_defaults.history = content_playlist_init(
g_settings.content_history_path,
g_settings.content_history_size);