diff options
author | Liang Qi <liang.qi@theqtcompany.com> | 2015-03-24 07:37:43 +0100 |
---|---|---|
committer | Liang Qi <liang.qi@theqtcompany.com> | 2015-03-24 07:38:02 +0100 |
commit | 135ebe4f3d268121047fdbfee49f2dd52006165e (patch) | |
tree | 6b303103f36e69e29cfa860b8b7afc584c55d6f3 /src/corelib/tools/qcollator_posix.cpp | |
parent | e7feb956280105113b3e58f12e5f32f54199a95a (diff) | |
parent | 1e8f50a8d069c97ea6a4f00d664c12e594884f54 (diff) |
Merge remote-tracking branch 'origin/5.5' into dev
Change-Id: If5d2e621c2fa5476c3ab687a3f4620c54fc3b32e
Diffstat (limited to 'src/corelib/tools/qcollator_posix.cpp')
-rw-r--r-- | src/corelib/tools/qcollator_posix.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/corelib/tools/qcollator_posix.cpp b/src/corelib/tools/qcollator_posix.cpp index 0b755825b7..352ab0ba31 100644 --- a/src/corelib/tools/qcollator_posix.cpp +++ b/src/corelib/tools/qcollator_posix.cpp @@ -78,8 +78,7 @@ int QCollator::compare(const QString &s1, const QString &s2) const QVarLengthArray<wchar_t> array1, array2; stringToWCharArray(array1, s1); stringToWCharArray(array2, s2); - int result = std::wcscoll(array1.constData(), array2.constData()); - return result > 0 ? 1 : (result == 0 ? 0 : -1); + return std::wcscoll(array1.constData(), array2.constData()); } int QCollator::compare(const QStringRef &s1, const QStringRef &s2) const |