Harden the icns handler
- Avoid potentially uninitialized data in output from reading rle24
encoded icons.
- Reject corrupt icons claiming to contain more data than available
from the input device, thus avoiding potential for overly large
memory allocation.
- Fix an off-by-one limit check in option(). (OOB was not currently
reachable, since the index is kept inside limits).
Task-number: QTBUG-148328
Pick-to: 6.12 6.11 6.8 6.5 5.15
Change-Id: I81441e8d1db7bd7f80cab592d009c21e48648fdd
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>