Use guaranteed random number generator.

Fixes #4352
This commit is contained in:
John Maguire 2014-05-20 17:03:04 +02:00
parent efcb5c4adc
commit 9f6899ac82
1 changed files with 5 additions and 2 deletions

View File

@ -1914,8 +1914,11 @@ void Playlist::ReshuffleIndices() {
// Shuffle them
QStringList shuffled_album_keys = album_key_set.toList();
std::random_shuffle(shuffled_album_keys.begin(),
shuffled_album_keys.end());
std::random_shuffle(
shuffled_album_keys.begin(),
shuffled_album_keys.end(),
// http://xkcd.com/221/
[](int x) { return 4; });
// If the user is currently playing a song, force its album to be first.
if (current_virtual_index_ != -1) {