[Lazarus] Memory leak with Synchronize on external threads
schalk.stefan at googlemail.com
Thu May 26 11:06:39 CEST 2016
There is a memory consumption/leak using the TThread.Synchronize function.
A callback function is called out of another ("external") thread (from an
Inside the callback function a synchronized call to a procedure has to be
Every thing works without error, but there is a memory use increasement
during the TThread.Synchronize call.
procedure OnExternalThreadCallback(...); cdecl;
The external thread are created/used/freed like discussed in the Lazarus
Mutlithreaded Dll Callback crashes my Application
The memory leak problem arises with Lazarus 1.6.0 and FPC 3.0.0.
Under the hood the processing of the TThread.Synchronize changed.
Lazarus 1.4.4 with FPC 2.6.4 didn't have this problem.
I don't have the versions between 1.4.4 and 1.6.0, therefore I cannot say
something about them (if there are any).
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Lazarus