From c6469c8341eac7ce6e0cec6993c1f9a778951a43 Mon Sep 17 00:00:00 2001 From: twinaphex Date: Mon, 15 Sep 2014 04:20:45 +0200 Subject: [PATCH] Set history path to playlists directory if playlist directory is non-NULL --- settings.c | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/settings.c b/settings.c index d7eef4cd2c..e1f7f00b12 100644 --- a/settings.c +++ b/settings.c @@ -1132,9 +1132,16 @@ bool config_load_file(const char *path, bool set_defaults) CONFIG_GET_INT(network_cmd_port, "network_cmd_port"); CONFIG_GET_BOOL(stdin_cmd_enable, "stdin_cmd_enable"); - fill_pathname_resolve_relative(g_settings.content_history_path, - g_extern.config_path, "retroarch-content-history.txt", - sizeof(g_settings.content_history_path)); + if (g_settings.playlist_directory[0] != '\0') + fill_pathname_join(g_settings.content_history_path, + g_settings.playlist_directory, + "retroarch-content-history.txt", + sizeof(g_settings.content_history_path)); + else + fill_pathname_resolve_relative(g_settings.content_history_path, + g_extern.config_path, "retroarch-content-history.txt", + sizeof(g_settings.content_history_path)); + CONFIG_GET_PATH(content_history_path, "game_history_path"); CONFIG_GET_INT(content_history_size, "game_history_size");