DDetours
DDetours copied to clipboard
AV when InterceptCreate called inside initialization section
initialization
InterceptCreate(@Dialogs.ShowMessage, @DialogHelper.ShowMessage);
Hi Sorien, Can you please include a simple demo ?
hmm, can't reproduce it in simple demo .. i'll try to debug it a bit
system.pas - function InitUnits https://gist.github.com/Sorien/5235bdfab2c33dd11ece
TProc(P)(); is calling initialization at my unit (code below)
initialization
InterceptCreate(@Dialogs.ShowMessage, @DialogHelper.ShowMessage);
in next itteration total count is changed ...
when i remove InterceptCreate/replace with old code hooking Count won't be changed
it looks really weird :/