Jeremy missed a bind() call when updating these demos. ;)

This commit is contained in:
Fred Drake 2000-08-25 16:03:27 +00:00
parent a8d30d5d66
commit 21801de6dc

View File

@ -18,7 +18,7 @@ def main():
else: else:
port = ECHO_PORT port = ECHO_PORT
s = socket(AF_INET, SOCK_STREAM) s = socket(AF_INET, SOCK_STREAM)
s.bind('', port) s.bind(('', port))
s.listen(1) s.listen(1)
conn, (remotehost, remoteport) = s.accept() conn, (remotehost, remoteport) = s.accept()
print 'connected by', remotehost, remoteport print 'connected by', remotehost, remoteport