summaryrefslogtreecommitdiffstats
path: root/tests/manual/qopenglwidget/openglwidget
diff options
context:
space:
mode:
authorPaul Olav Tvete <paul.tvete@qt.io>2024-02-27 16:18:33 +0100
committerPaul Olav Tvete <paul.tvete@qt.io>2024-03-01 18:00:33 +0000
commit997fd3b88ede8078af286da6ecc197e83a8cbb46 (patch)
tree0b7cc0d345b285c950797d47acc5666831c98793 /tests/manual/qopenglwidget/openglwidget
parent7bde3f4c4c6b4c27ce4ce45b6735d61f405ea53b (diff)
QTextEngine: Protect against integer overflow with huge texts
QPlainTextEdit would crash when adding a string of 136 348 169 characters, due to the integer overflow checks being done with int variables. Perform intermediate calculations and size checks with qsizetype instead of int. This commit contains a slight modification of the fix contributed by Adam Clarke in the bug report. Note that the size check casts to size_t to cover the 32-bit case where qsizetype is qint32. Fixes: QTBUG-119611 Pick-to: 6.7 Change-Id: I1cf7e1bc4c35276862f37aa6d01f37075fa11635 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
Diffstat (limited to 'tests/manual/qopenglwidget/openglwidget')
0 files changed, 0 insertions, 0 deletions