Debugging a Delphi – Format and Pointers/Hex Values (Memory Overwrite) – Stack Overflow
Posted by jpluimers on 2021/01/12
A long time ago (Delphi XE2 era), David Dubois and I helped out Doug find either the cause or a workaround of a memory overwrite in a 32-bit application.
The problem was that a call to Format for a pointe or hex value would give corrupt results, but with a regular integer value it would succeed.
Doug created an example [WayBack] overwriting some memory to simulate the problem.
I provided some steps [WayBack] to help trace such cases down.
In the and a rebuild – first withut madExcept, later with madExcept turned on again – solved the problem.
Likely this was the Delphi IDE becoming corrupt, something which I have seen intermittently over the last two decades.
Be sure to read both answers at [WayBack] delphi – Format and Pointers/Hex Values (Memory Overwrite) – Stack Overflow
–jeroen
Leave a comment