msg = conn.recv(BUFSIZE) #接受消息的内容
-----------------------
<socket._socketobject object at 0x7fdd08d8cad0>
('192.168.137.1', 57504)
接到来自192.168.137.1的链接
-----------------------
123456789
-----------------------
-----------------------
0
-----------------------
客户端发送
s.send('1234567890') 10位数字
Receive data from the socket. The return value is a string representing the data received.
The maximum amount of data to be received at once is specified by bufsize.
See the Unix manual page recv(2) for the meaning of the optional argument flags; it defaults to zero.
Note For best match with hardware and network realities, the value of bufsize should be a relatively small power of 2, for example, 4096.
从socket接收数据,返回值是一个字符串反应接收的数据。
通过设置bufsize 表示一次能接收的最大数据