[EMAIL PROTECTED] wrote:
Until now, I've been
doing this little trick:

data = client.recv(256)
new = data
while len(new) == 256:
    new = client.recv(256)
    data += new

Are you aware that recv() will not always return the amount of bytes asked for?
(send() is similar; it doesn't guarantee that the full buffer you pass to it will be sent at once)

I suggest reading this: http://www.amk.ca/python/howto/sockets/sockets.html


--irmen
--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to