Send data packets

Started by
13 comments, last by DimSum 21 years, 6 months ago
i have made a client-server application using vb winsock control, and I realized that the packets I send to the cliend can arrive in different order and even not reach client''s port.

Because of my hurry I was forced to code a queue for output messages and a custom protocol to verify every packet is sent in order and that arrives safely to the client, If not after n seconds I do a resend of that message. I do validate on client side that I haven''t already recieved that message, I use msg-id number to identify them. Do I am a lammer at this? I''m using TCP-IP protocol, not UDP.

I post this, because if this is a common issue to winsock, it could be usefull, and if it isnt it could be usefull to take me as a bad example: "you shouldn''t do like xaxa did". Either way I could learn, so please FLAME ME AS WELL
[size="2"]I like the Walrus best.
Advertisement
Doesn''t TCP guarantee in-order receipt of messages? I read a protocol book on it once but haven''t had to implement it in software so I don''t know the answer personally.
I think so.
Chess is played by three people. Two people play the game; the third provides moral support for the pawns. The object of the game is to kill your opponent by flinging captured pieces at his head. Since the only piece that can be killed is a pawn, the two armies agree to meet in a pawn-infested area (or even a pawn shop) and kill as many pawns as possible in the crossfire. If the game goes on for an hour, one player may legally attempt to gouge out the other player's eyes with his King.
Yes. The TCP protocol, as one of it''s requirements, is guaranteed packet delivery, and also guaranteed first-send-first-received packet order.
daerid@gmail.com
well, it doesn''t work with VB Winsock Control.

FLAME
FLAME
FLAME
[size="2"]I like the Walrus best.

This topic is closed to new replies.

Advertisement