From 1241a02a01183541ed4e3a3367e275c9094f84a1 Mon Sep 17 00:00:00 2001 From: Giuseppe D'Angelo Date: Wed, 4 Apr 2012 16:21:03 +0100 Subject: [PATCH] qHash: always use the seed in the catch-all template MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 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 Reviewed-by: Oswald Buddenhagen --- src/corelib/tools/qhash.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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 inline uint qHash(const QPair &key) return ((h1 << 16) | (h1 >> 16)) ^ h2; } -template inline uint qHash(const T &t, uint) { return qHash(t); } +template inline uint qHash(const T &t, uint seed) { return (qHash(t) ^ seed); } struct Q_CORE_EXPORT QHashData {