Re: [twsocket] Trouble with ICS v7
Denis Gottardello wrote: > Il 13/12/2011 15.52, Arno Garrels ha scritto: >> Denis Gottardello wrote: >>> I use ICS components in a my application. I have a problem with >>> TWSocket and ServerWSocketDataAvailable. Sometimes, when the >>> ServerWSocketDataAvailable event is called and in action, the same >>> event is called again, before the previous instance is terminated. >>> >>> I use line mode, #13#10 as line terminator and BufferIn:= >>> TWSocket(Sender).ReceiveStr(); >>> I not use anything like ProcessMessage or other. >> Perhaps some code indirectly calls the message pump? >> For instance ShowMessage(). >> > Nothing. Is because I use a limemode way? No, I do not think so, I use ICS since many years and haven't seen such reentries when used properly. Are you any chance using the component in a worker thread? -- Arno Garrels -- 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
Re: [twsocket] Trouble with ICS v7
>>> I use ICS components in a my application. I have a problem with >>> TWSocket and ServerWSocketDataAvailable. Sometimes, when the >>> ServerWSocketDataAvailable event is called and in action, the same >>> event is called again, before the previous instance is terminated. >>> >>> I use line mode, #13#10 as line terminator and BufferIn:= >>> TWSocket(Sender).ReceiveStr(); I not use anything like ProcessMessage >>> or other. >> Perhaps some code indirectly calls the message pump? >> For instance ShowMessage(). > Nothing. Is because I use a limemode way? No, line mode has nothing to do with that. The symptoms you describe (reentry in an event handler) are ALWAYS caused by calling the message pump, directly or indirectly. You should be able to see where it is called by looking at the call stack if you can manage to put a breakpoint at the time the event handler is reentered. You could compare the call stack at the time of reentry with the call stack when no reentry occur. FYI, anything which display something on screen and wait for user interaction is calling the message pump ! -- francois.pie...@overbyte.be The author of the freeware multi-tier middleware MidWare The author of the freeware Internet Component Suite (ICS) http://www.overbyte.be -- 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
Re: [twsocket] Trouble with ICS v7
Il 13/12/2011 15.52, Arno Garrels ha scritto: Denis Gottardello wrote: I use ICS components in a my application. I have a problem with TWSocket and ServerWSocketDataAvailable. Sometimes, when the ServerWSocketDataAvailable event is called and in action, the same event is called again, before the previous instance is terminated. I use line mode, #13#10 as line terminator and BufferIn:= TWSocket(Sender).ReceiveStr(); I not use anything like ProcessMessage or other. Perhaps some code indirectly calls the message pump? For instance ShowMessage(). Nothing. Is because I use a limemode way? -- Denis Gottardello Sintesi S.r.l. 049.9301135 -- 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
Re: [twsocket] Trouble with ICS v7
Denis Gottardello wrote: > I use ICS components in a my application. I have a problem with > TWSocket and ServerWSocketDataAvailable. Sometimes, when the > ServerWSocketDataAvailable event is called and in action, the same > event is called again, before the previous instance is terminated. > > I use line mode, #13#10 as line terminator and BufferIn:= > TWSocket(Sender).ReceiveStr(); > I not use anything like ProcessMessage or other. Perhaps some code indirectly calls the message pump? For instance ShowMessage(). -- Arno Garrels -- 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
[twsocket] Trouble with ICS v7
I use ICS components in a my application. I have a problem with TWSocket and ServerWSocketDataAvailable. Sometimes, when the ServerWSocketDataAvailable event is called and in action, the same event is called again, before the previous instance is terminated. I use line mode, #13#10 as line terminator and BufferIn:= TWSocket(Sender).ReceiveStr(); I not use anything like ProcessMessage or other. How can I do to resolv this problem? -- Denis Gottardello Sintesi S.r.l. 049.9301135 -- 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