Skip to content
Extraits de code Groupes Projets
Valider 3c599034 rédigé par Thomas Goyne's avatar Thomas Goyne
Parcourir les fichiers

Work around an incorrect assertion in older versions of boost. Closes #1702.

parent 0523c273
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
......@@ -60,7 +60,15 @@ std::shared_ptr<VideoFrame> VideoProviderCache::GetFrame(int n) {
for (auto cur = cache.begin(); cur != cache.end(); ++cur) {
if (cur->frame_number == n) {
#if BOOST_VERSION <= 105200
// Until boost 1.52, boost::container::list incorrectly asserted
// that this != &other, so do an extra splice through an empty list
decltype(cache) temp;
temp.splice(temp.begin(), cache, cur);
cache.splice(cache.begin(), temp, temp.begin());
#else
cache.splice(cache.begin(), cache, cur); // Move to front
#endif
return std::make_shared<VideoFrame>(cache.front());
}
......
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Terminez d'abord l'édition de ce message.
Veuillez vous inscrire ou vous pour commenter