diff options
| author | Giuseppe D'Angelo <giuseppe.dangelo@kdab.com> | 2025-01-27 17:36:28 +0100 |
|---|---|---|
| committer | Giuseppe D'Angelo <giuseppe.dangelo@kdab.com> | 2025-01-28 17:12:45 +0100 |
| commit | 0f336500a0add3e3a8bb31c5cc605e5e13e23833 (patch) | |
| tree | ef74c05e16da2e009164027eaf73c5e52ca6f9c7 /src/gui/platform/unix/qdesktopunixservices.cpp | |
| parent | b5538a5a0ebf9bd9a155b857c385c764c30eabae (diff) | |
QDebug: do not trigger integer overflow when printing a QRect
QRect::width() and height() may overflow: they're only safe to call
when right-left+1 (or bottom-top+1) is representable by an `int`.
Therefore, avoiding calling them from QDebug, which is supposed to
"always work" (otherwise, it's not of great debugging help...).
QRectF does not have this issue as it stores the width directly.
Change-Id: I438dbacae42c17730afb92f05d16e3eebb161255
Pick-to: 6.9 6.8 6.5
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'src/gui/platform/unix/qdesktopunixservices.cpp')
0 files changed, 0 insertions, 0 deletions
