python network programming--connect()
摘要:
首先我们看一段python client/server代码。server端:>>> import sys,socket>>> s = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)>>> MAX = 65535>>> PORT = 1060>>> s.bind(('127.0.0.1', PORT))>>> print 'Listening at', s.getsockname()Listening at 阅读全文
posted @ 2013-12-18 16:49 kramer 阅读(449) 评论(0) 推荐(0) 编辑