summaryrefslogtreecommitdiffstats
path: root/src/gui/image
diff options
context:
space:
mode:
authorLiang Qi <liang.qi@qt.io>2017-03-13 19:45:20 +0000
committerThe Qt Project <gerrit-noreply@qt-project.org>2017-03-13 19:45:20 +0000
commit77e71dac1607232160006579420df8b603118462 (patch)
tree8fe71cc79127465f63944eb0dd48a00478546f57 /src/gui/image
parent70e772079f4943822cc469ef83fb9c43afc36514 (diff)
parentd51c3ecf8ef6e28557c66745f50a223cc5b1ce54 (diff)
Merge "Merge remote-tracking branch 'origin/5.8' into 5.9" into refs/staging/5.9
Diffstat (limited to 'src/gui/image')
-rw-r--r--src/gui/image/qpixmapcache.cpp7
1 files changed, 0 insertions, 7 deletions
diff --git a/src/gui/image/qpixmapcache.cpp b/src/gui/image/qpixmapcache.cpp
index 73448943e1..625e145647 100644
--- a/src/gui/image/qpixmapcache.cpp
+++ b/src/gui/image/qpixmapcache.cpp
@@ -341,7 +341,6 @@ bool QPMCache::insert(const QString& key, const QPixmap &pixmap, int cost)
} else {
//Insertion failed we released the new allocated key
cacheKeys.remove(key);
- releaseKey(cacheKey);
}
return success;
}
@@ -355,9 +354,6 @@ QPixmapCache::Key QPMCache::insert(const QPixmap &pixmap, int cost)
theid = startTimer(flush_time);
t = false;
}
- } else {
- //Insertion failed we released the key and return an invalid one
- releaseKey(cacheKey);
}
return cacheKey;
}
@@ -377,9 +373,6 @@ bool QPMCache::replace(const QPixmapCache::Key &key, const QPixmap &pixmap, int
t = false;
}
const_cast<QPixmapCache::Key&>(key) = cacheKey;
- } else {
- //Insertion failed we released the key
- releaseKey(cacheKey);
}
return success;
}