mirror of
https://github.com/libretro/RetroArch
synced 2025-04-03 10:21:31 +00:00
Portable playlists: fixed first load initialization
This commit is contained in:
parent
06210387af
commit
6fa08b5287
11
playlist.c
11
playlist.c
@ -2724,11 +2724,12 @@ playlist_t *playlist_init(const playlist_config_t *config)
|
|||||||
|
|
||||||
/* Try auto-fixing paths if enabled, and playlist
|
/* Try auto-fixing paths if enabled, and playlist
|
||||||
* base content directory is different */
|
* base content directory is different */
|
||||||
if (playlist->config.autofix_paths &&
|
if (config->autofix_paths && !string_is_equal(playlist->base_content_directory, config->base_content_directory))
|
||||||
!string_is_empty(playlist->base_content_directory) &&
|
|
||||||
!string_is_equal(playlist->base_content_directory,
|
|
||||||
playlist->config.base_content_directory))
|
|
||||||
{
|
{
|
||||||
|
if (!string_is_empty(playlist->base_content_directory))
|
||||||
|
{
|
||||||
|
size_t playlist_base_content_directory_length = strlen(playlist->base_content_directory);
|
||||||
|
size_t new_base_content_directory_length = strlen(playlist->config.base_content_directory);
|
||||||
size_t i, j, len;
|
size_t i, j, len;
|
||||||
char tmp_entry_path[PATH_MAX_LENGTH];
|
char tmp_entry_path[PATH_MAX_LENGTH];
|
||||||
|
|
||||||
@ -2777,8 +2778,10 @@ playlist_t *playlist_init(const playlist_config_t *config)
|
|||||||
entry->subsystem_roms = subsystem_roms_new_paths;
|
entry->subsystem_roms = subsystem_roms_new_paths;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/* Update playlist base content directory*/
|
/* Update playlist base content directory*/
|
||||||
|
if (playlist->base_content_directory)
|
||||||
free(playlist->base_content_directory);
|
free(playlist->base_content_directory);
|
||||||
playlist->base_content_directory = strdup(playlist->config.base_content_directory);
|
playlist->base_content_directory = strdup(playlist->config.base_content_directory);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user