diff options
-rw-r--r-- | src/corelib/text/qstring.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/corelib/text/qstring.cpp b/src/corelib/text/qstring.cpp index fea5fb00df..49ddb9279b 100644 --- a/src/corelib/text/qstring.cpp +++ b/src/corelib/text/qstring.cpp @@ -3038,7 +3038,8 @@ QChar *textCopy(const QChar *start, int len) bool pointsIntoRange(const QChar *ptr, const ushort *base, int len) { const QChar *const start = reinterpret_cast<const QChar *>(base); - return start <= ptr && ptr < start + len; + const std::less<const QChar *> less; + return !less(ptr, start) && less(ptr, start + len); } } // end namespace |