[fpc-devel] Why/how does the compiler have a non-trivialnumberofmemory leaks after over two decades of development?

Sven Barth pascaldragon at googlemail.com
Mon Jul 30 23:10:28 CEST 2018


Am 30.07.2018 um 19:49 schrieb J. Gareth Moreton:
> The trouble is, these allocation failures are designed for C programs, 
> where "malloc" returns NULL if memory isn't allocated.  Free Pascal's 
> GetMem raises an exception instead. Granted, it shouldn't be too much 
> of a struggle to implement a custom memory manager for testing and to 
> cause random (or deterministic) allocation failures to see how cleanly 
> the situation is handled.  It could be a fun test suite!
The default heap of FPC's RTL respects the value of 
ReturnNilIfGrowHeapFails (which by default is False).

Regards,
Sven
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freepascal.org/pipermail/fpc-devel/attachments/20180730/03a8bc3a/attachment.html>


More information about the fpc-devel mailing list