mirror of
https://github.com/Rockbox/rockbox.git
synced 2026-01-22 01:30:35 -05:00
create the playlist directory instead of warning it doesnt exist when entering the playlist cataloge
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@10640 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
5119b18e93
commit
4293482bf0
1 changed files with 10 additions and 4 deletions
|
|
@ -111,14 +111,20 @@ static int initialize_catalog(void)
|
|||
|
||||
if (!playlist_dir_exists)
|
||||
{
|
||||
gui_syncsplash(HZ*2, true, str(LANG_CATALOG_NO_DIRECTORY),
|
||||
playlist_dir);
|
||||
return -1;
|
||||
if (mkdir(playlist_dir, 0) < 0) {
|
||||
gui_syncsplash(HZ*2, true, str(LANG_CATALOG_NO_DIRECTORY),
|
||||
playlist_dir);
|
||||
return -1;
|
||||
}
|
||||
else {
|
||||
playlist_dir_exists = true;
|
||||
memset(most_recent_playlist, 0, sizeof(most_recent_playlist));
|
||||
initialized = true;
|
||||
}
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
/* Use the filetree functions to retrieve the list of playlists in the
|
||||
directory */
|
||||
static int create_playlist_list(char** playlists, int num_items,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue