OSDN Git Service
(root)
/
kde
/
Katie.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
95ae740
)
use qAtomicAssign() in QIcon::operator=()
author
Ivailo Monev
<xakepa10@gmail.com>
Wed, 24 Nov 2021 17:24:26 +0000
(19:24 +0200)
committer
Ivailo Monev
<xakepa10@gmail.com>
Wed, 24 Nov 2021 17:24:26 +0000
(19:24 +0200)
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
src/gui/image/qicon.cpp
patch
|
blob
|
history
diff --git
a/src/gui/image/qicon.cpp
b/src/gui/image/qicon.cpp
index
2d4dfd4
..
1d35fd1
100644
(file)
--- a/
src/gui/image/qicon.cpp
+++ b/
src/gui/image/qicon.cpp
@@
-529,11
+529,7
@@
QIcon::~QIcon()
*/
QIcon &QIcon::operator=(const QIcon &other)
{
- if (other.d)
- other.d->ref.ref();
- if (d && !d->ref.deref())
- delete d;
- d = other.d;
+ qAtomicAssign(d, other.d);
return *this;
}