Crash (sigsegv) or Exception caused by TProcessUtf8
Original Reporter info from Mantis: Martin @martin_frb
-
Reporter name: Martin Friebe
Original Reporter info from Mantis: Martin @martin_frb
- Reporter name: Martin Friebe
Description:
Compiling either
- LazUtils,
- or the RTL
with -O4 will cause TProcessUtf8 to fail.
It can either
- raise an exception
- write to memory out of bounds, causing random errors (including SigSegv) at a later time.
This is caused by trying to "guess" the byte offset of a private field and modify it.
However with -O4 FPC may change the order of fields.
This is also extremely unstable with regards to future changes in fpc.
This may also fail, if WPO is used (not verified).
This is a result of the fix for #28991 (closed) revision 50595
Mantis conversion info:
- Mantis ID: 35991
- OS: win 10
- OS Build: 10
- Platform: 64bit Intel
- Version: 2.1 (SVN)
- Fixed in revision: r63584 (#3d951e3e), r63708 (#3a6057e0)
- Monitored by: » @baldzhang (bald zhang), » @marcoonthegit (Marco van de Voort)