Always set random seed before inserting tracks shuffled. Fixes problem with shuffle always being the same when inserting immediately after startup.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@10956 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
16c55277f7
commit
8fe4507dc7
1 changed files with 4 additions and 0 deletions
|
@ -177,6 +177,10 @@ static bool add_to_playlist(int position, bool queue)
|
|||
if (new_playlist)
|
||||
playlist_create(NULL, NULL);
|
||||
|
||||
/* always set seed before inserting shuffled */
|
||||
if (position == PLAYLIST_INSERT_SHUFFLED)
|
||||
srand(current_tick);
|
||||
|
||||
if (context == CONTEXT_ID3DB)
|
||||
{
|
||||
tagtree_insert_selection_playlist(position, queue);
|
||||
|
|
Loading…
Reference in a new issue