[Python] Socket.sendto and Buffer()

Alessandro Cattaneo alessandro.cattaneo83 a gmail.com
Ven 10 Lug 2009 09:55:20 CEST


Hello everyone

I have a question, in an application I'm about to modify I have to  
switch from a TCP socket to a UDP socket, and
I need to understand a thing. In the original code the data to be sent  
is incapsulated in a Buffer() object.
This means that if my application do a socket.sendto(Buffer()) , it  
will be sent as many packet as (data dimension)/ (buffer dimension)?
When the packet will be received what happens?Who cares about rebuild  
the the original data?
If I do the same thing on an UDP socket, what happens?the data will be  
rebuilt in the same way?Or there is some issue about the
possibility of out of order of the packets?

Thank to you all, I hope in some answer :))


Alessandro


Maggiori informazioni sulla lista Python