diff options
author | Giuseppe D'Angelo <dangelog@gmail.com> | 2012-04-04 16:21:03 +0100 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2012-04-06 22:51:24 +0200 |
commit | 1241a02a01183541ed4e3a3367e275c9094f84a1 (patch) | |
tree | cd418461538aa41111842863ff14e4fd87811e92 /src | |
parent | 9ddb822a8672af8495ee6e3e30449800c96589e4 (diff) |
qHash: always use the seed in the catch-all template
This pertubates the results of the calls to the one-argument
version of qHash through the catch-all template.
Change-Id: I7037b25d545e6f1360384a83ff895f4bb62ed195
Reviewed-by: João Abecasis <joao.abecasis@nokia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/corelib/tools/qhash.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/corelib/tools/qhash.h b/src/corelib/tools/qhash.h index 8fe66aac76..42c33f6f78 100644 --- a/src/corelib/tools/qhash.h +++ b/src/corelib/tools/qhash.h @@ -109,7 +109,7 @@ template <typename T1, typename T2> inline uint qHash(const QPair<T1, T2> &key) return ((h1 << 16) | (h1 >> 16)) ^ h2; } -template<typename T> inline uint qHash(const T &t, uint) { return qHash(t); } +template<typename T> inline uint qHash(const T &t, uint seed) { return (qHash(t) ^ seed); } struct Q_CORE_EXPORT QHashData { |