Skip to content
Commit bf2685a3 authored by Maciej Stanczew's avatar Maciej Stanczew Committed by Oliver Beard
Browse files

sensors: Correctly handle the return value of QCollator::compare

QCollator::compare() can return any integer, not just [-1, 0, 1].
Comparing the result with -1 happened to work with most locales,
but it broke with the C locale. As a result, when sensors were put
into std::map, they were sometimes erroneously treated as duplicates,
leading to a randomly incomplete and garbled sensor list.

BUG: 461070


(cherry picked from commit 0a7efca4)
parent 9976f1e2
Pipeline #459053 passed with stage
in 1 minute and 8 seconds
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment