summaryrefslogtreecommitdiffstats
path: root/src/corelib
diff options
context:
space:
mode:
authorJoão Abecasis <joao.abecasis@nokia.com>2010-08-26 11:47:33 (GMT)
committerJoão Abecasis <joao.abecasis@nokia.com>2010-09-07 12:17:04 (GMT)
commitc3c30e16a2bb5ab9236946aa6c48ca02ef2afa08 (patch)
treee46abdb27eb08b68b9b89267d43c6f4c286eeb2f /src/corelib
parent1885c88c5721f026d3b0c01dbc756857a79cce91 (diff)
downloadQt-c3c30e16a2bb5ab9236946aa6c48ca02ef2afa08.zip
Qt-c3c30e16a2bb5ab9236946aa6c48ca02ef2afa08.tar.gz
Qt-c3c30e16a2bb5ab9236946aa6c48ca02ef2afa08.tar.bz2
QDir::operator= simplification
With the recent changes to QDirPrivate and how d_ptr is now a QSharedDataPointer, we no longer need to worry about self-assignment, as that is already handled by the d_ptr. Simplifying code here. Reviewed-by: Prasanth Ullattil
Diffstat (limited to 'src/corelib')
-rw-r--r--src/corelib/io/qdir.cpp3
1 files changed, 0 insertions, 3 deletions
diff --git a/src/corelib/io/qdir.cpp b/src/corelib/io/qdir.cpp
index 7c38ecf..b35cd2b 100644
--- a/src/corelib/io/qdir.cpp
+++ b/src/corelib/io/qdir.cpp
@@ -1634,9 +1634,6 @@ bool QDir::operator==(const QDir &dir) const
*/
QDir &QDir::operator=(const QDir &dir)
{
- if (this == &dir)
- return *this;
-
d_ptr = dir.d_ptr;
return *this;
}