Re: [twsocket] Hang in TIcsWndControl.ProcessMessages

2011-07-13 Thread Arno Garrels
Angus Robertson - Magenta Systems Ltd wrote: >>> Waiting for all sockets to close cleanly may be necessary before >>> terminating an application, to ensure continuously streamed data >>> is not lost. >> >> I do not see a reason why one must wait in a loop processing >> messages with calls to sleep

Re: [twsocket] Hang in TIcsWndControl.ProcessMessages

2011-07-13 Thread Angus Robertson - Magenta Systems Ltd
> > Waiting for all sockets to close cleanly may be necessary before > > terminating an application, to ensure continuously streamed data > > is not lost. > > I do not see a reason why one must wait in a loop processing > messages with calls to sleep()in order to achieve that, that's > often a

Re: [twsocket] Hang in TIcsWndControl.ProcessMessages

2011-07-13 Thread Arno Garrels
Angus Robertson - Magenta Systems Ltd wrote: >> Looks like you try to workaround the asynchronous nature of TWSocket >> which were a bad idea. Where do you call this and what do you want >> to achieve? > > Waiting for all sockets to close cleanly may be necessary before > terminating an applicatio

Re: [twsocket] Hang in TIcsWndControl.ProcessMessages

2011-07-13 Thread Angus Robertson - Magenta Systems Ltd
> Looks like you try to workaround the asynchronous nature of TWSocket > which were a bad idea. Where do you call this and what do you want > to achieve? Waiting for all sockets to close cleanly may be necessary before terminating an application, to ensure continuously streamed data is not lost.

Re: [twsocket] Hang in TIcsWndControl.ProcessMessages

2011-07-13 Thread Arno Garrels
Eugene Kotlyarov wrote: Does anyone have ideas why TIcsWndControl.ProcessMessages could hang sometimes when socket is used in separate thread? >> >>> Have you followed the rules: create TWSocket within the thread's >>> execute method OR call ThreadAttach ? >> >> Yes socket is created wi

Re: [twsocket] Hang in TIcsWndControl.ProcessMessages

2011-07-12 Thread Eugene Kotlyarov
> I call it like this, the only event that is called is SslShutDownComplete > which > sets FSSLShutdownComplete property, I don't have any other event > processing here > > FSocket.Shutdown(SD_BOTH); > > EndTime := GetTickCount + FTimeout; > while {$IFDEF USE_SSL} not FSSLShutdownComplete {$EL

Re: [twsocket] Hang in TIcsWndControl.ProcessMessages

2011-07-12 Thread Francois PIETTE
Does anyone have ideas why TIcsWndControl.ProcessMessages could hang sometimes when socket is used in separate thread? Actually ProcessMessages probably doesn't hang. ProcessMessages it the place from where all events are called. It is likely an event handler which is blocking. You should try

Re: [twsocket] Hang in TIcsWndControl.ProcessMessages

2011-07-12 Thread Eugene Kotlyarov
>>> Does anyone have ideas why TIcsWndControl.ProcessMessages could >>> hang sometimes when socket is used in separate thread? > >>Have you followed the rules: create TWSocket within the thread's execute >>method OR call ThreadAttach ? > > Yes socket is created within threads execute method, and it

Re: [twsocket] Hang in TIcsWndControl.ProcessMessages

2011-07-08 Thread Francois PIETTE
Does anyone have ideas why TIcsWndControl.ProcessMessages could hang sometimes when socket is used in separate thread? Have you followed the rules: create TWSocket within the thread's execute method OR call ThreadAttach ? Yes socket is created within threads execute method, and it works most

Re: [twsocket] Hang in TIcsWndControl.ProcessMessages

2011-07-07 Thread Eugene Kotlyarov
>> Does anyone have ideas why TIcsWndControl.ProcessMessages could >> hang sometimes when socket is used in separate thread? >Have you followed the rules: create TWSocket within the thread's execute >method OR call ThreadAttach ? Yes socket is created within threads execute method, and it works

Re: [twsocket] Hang in TIcsWndControl.ProcessMessages

2011-07-07 Thread Francois PIETTE
Does anyone have ideas why TIcsWndControl.ProcessMessages could hang sometimes when socket is used in separate thread? Have you followed the rules: create TWSocket within the thread's execute method OR call ThreadAttach ? -- francois.pie...@overbyte.be The author of the freeware multi-tier mi

[twsocket] Hang in TIcsWndControl.ProcessMessages

2011-07-07 Thread Eugene Kotlyarov
Hi Everyone Does anyone have ideas why TIcsWndControl.ProcessMessages could hang sometimes when socket is used in separate thread? -- 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:/