I am trying to trace memory leaks reported by AQTime and I suspect it may have something to do with the design of my application, the HTTPCli component, and the multi-threaded limitations of the VCL.
I have an EXE which loads a dynamic DLL. Both of them built with C++Builder 2009 and using the latest ICS V7 (from http://www.overbyte.be/cgi-bin/redirect.cgi?url=http://www.overbyte.be/arch/ OverbyteIcsV7.zip). In the DLL, I have a link checker that uses ICS. It creates multiple worker threads and multiple HTTPCli objects and uses asynchronous calls. AQTime reports small memory leaks. Originally it was when calling Application->ProcessMessages(), but I think that was wrong since I know now that should only be called from the main VCL thread. So I created my own message loop: void AWProcessMessages(void) { MSG Msg; while(PeekMessage(&Msg, NULL, 0, 0, PM_REMOVE) > 0) { TranslateMessage(&Msg); DispatchMessage(&Msg); // memory leaks? } } I call that instead of ProcessMessages() in the DLL threads, but AQTime is still reporting memory leaks, I believe for the line DispatchMessage(). 1. First, is there a problem creating HTTPCli components in DLL created threads that are not the main VCL thread? If so, could this be the problem and is there a workaround? I suspect processing the messages may be resulting in VCL functions being called by a non-VCL safe thread (not the main VCL thread). 2. Any other ideas what might be causing these small memory leaks AQTime is reporting? Or perhaps they could be false? Thanks! -- Albert Wiersch AI Internet Solutions supp...@htmlvalidator.com http://www.htmlvalidator.com/ -- To unsubscribe or change your settings for TWSocket mailing list please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket Visit our website at http://www.overbyte.be