Hello,

I did some changes now (I will onl make changes to my communication dll 
which don't affect the other communication methods).

I derrived a descendant from TWSocket which implements the OnSessionClosed 
method
and overrides create to assign my OnSessionClosed variant to the property.

In my variant only self.release is called.

At the point where I want to terminate the socket I do it like follows now:

- output a debug message to eventlog
- socket.shutdown(1);
- output a 2nd message to eventlog
- do this:
  t:=GetTickCount;
  while (GetTickCount-t < 100) do
  begin
    TranslateMessage(MsgRec);
    DispatchMessage(MsgRec);
    WaitMessage; 
  end;
- output a 3rd message to eventlog
- Socket.Release;

But: it doesn't even get to the 2nd message!
I will put a message in my OnSessionClosed  event as well.

But I don't know why the 2nd message (and all later) aren't written.
The main program still hangs for some seconds. After that a 2nd click on 
close can be done which works then (at least closes the app.)

Greetings

Markus Humm
-- 
To unsubscribe or change your settings for TWSocket mailing list
please goto http://www.elists.org/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be

Reply via email to