diff options
author | Berthold Stoeger <bstoeger@mail.tuwien.ac.at> | 2017-11-26 23:48:41 +0100 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2017-11-26 18:49:05 -0800 |
commit | bf65f1e507c508428e46b06152d08494b426f69f (patch) | |
tree | dc885f43d0810d9c57880d1d41f84a56c48ecaf8 /desktop-widgets | |
parent | d1545b27b45db1b06cad56eb366757208dfa120b (diff) | |
download | subsurface-bf65f1e507c508428e46b06152d08494b426f69f.tar.gz |
Fix comparison function in qt-models/divelocationmodel.cpp
The function dive_site_less_than() in qt-models/divelocationmodel.cpp
does not what it promises: it uses less-or-equal instead of less-than
comparison.
Note that, even though this may sound pedantic, this is an actual bug.
Usually, sorting functions suppose that they are provided with
strict weak ordering, which <= does *not* provide.
This is the actual reason for the crash mentioned in commit
f8a3a8521003a26525b658840ce8e7bfd3f7b141.
While touching this function, make it of static linkage, since
its usage is local to this translation unit.
Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Diffstat (limited to 'desktop-widgets')
0 files changed, 0 insertions, 0 deletions