Android: bounds-check word range before slicing the spoken text


processNotifyRangeStart() receives start/end indices from the Android
text-to-speech engine via a JNI callback and uses them to slice m_text.
Unlike the Darwin and SAPI backends, which guard against out-of-range
word boundaries, an index outside the current text would violate
QString::sliced()'s preconditions and invoke UB.

Validate that the reported range lies within m_text before emitting
sayingWord(), matching the behavior of the other backends.

Pick-to: 6.12 6.11 6.8
Change-Id: Ifb3bdbfcecbf234b67bbc8f43437075a85fc1c55
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
commit2d2c49a881694eff74fbf54c86efc05e46c38650
parentc259626275c981f2e31f75be0ad62626c2c7443e
authorVolker Hilsheimer <volker.hilsheimer@qt.io>
committerVolker Hilsheimer <volker.hilsheimer@qt.io>
commit timeFri, 3 Jul 2026 14:24:36 +0000