fix the socketserver demo code for py3k

#4275 Thanks to Don MacMillen
This commit is contained in:
Benjamin Peterson 2008-11-08 17:24:34 +00:00
parent ef6a19e3ea
commit 06fd5f8cc8
5 changed files with 38 additions and 30 deletions

View file

@ -6,7 +6,7 @@ from socket import *
FILE = 'unix-socket'
s = socket(AF_UNIX, SOCK_STREAM)
s.connect(FILE)
s.send('Hello, world')
s.send(b'Hello, world')
data = s.recv(1024)
s.close()
print('Received', repr(data))