mirror of
https://github.com/clementine-player/Clementine
synced 2025-01-31 11:35:24 +01:00
Fix memory leak in pixmap disk cache
This commit is contained in:
parent
b2bd7828c4
commit
b463f32459
@ -508,7 +508,8 @@ void LibraryModel::AlbumArtLoaded(quint64 id, const QImage& image) {
|
||||
}
|
||||
|
||||
// if not already in the disk cache
|
||||
if (!icon_cache_->data(QUrl(cache_key))) {
|
||||
std::unique_ptr<QIODevice> cached_img (icon_cache_->data(QUrl(cache_key)));
|
||||
if (!cached_img) {
|
||||
QNetworkCacheMetaData item_metadata;
|
||||
item_metadata.setSaveToDisk(true);
|
||||
item_metadata.setUrl(QUrl(cache_key));
|
||||
|
Loading…
x
Reference in New Issue
Block a user