Am 06.12.2014 13:00, schrieb twsocket-requ...@lists.elists.org:
> procedure TLobbyServer.SocketServerDataAvailable(Sender: TObject; ErrCode: 
> Word);
> begin
>    if ErrCode <> 0 then Exit;
>   with Sender as TWSocketClient do
>   begin
>     RunCommand(ReceiveStr, Sender as TWSocketClient);
>   end;
> end;

Hello,

unless you use LineMode the code above doesn't guarantee that each of
your command strings is being transmitted in one single string over the
network. So it could be that you get several SocketServerDataAvailable
events for the same command, each containing another part of the string.
The only guarantee you have in such a case is, that the order in which
you get the events is the correct one.

=> either use line mode or implement your own buffering system

Greetings

Markus
-- 
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

Reply via email to