Message253418
socket created with listening socket set to setblocking(False). gettimeout() of accept()-returned socket returns 0.0 , but recv() method blocks while client is connected and not sending any data. If client disconnects, socket returned by accept() starting return 0-length bytes string without blocking.
glibc doc on recv():
---
If nonblocking mode is set for SOCKET, and no data are available to be read, 'recv' fails immediately rather than waiting.
---
testing server and client code attached.
tested with Python 3.5.0 and Python 2.7.10 |
|
| Date |
User |
Action |
Args |
| 2015-10-24 23:03:30 | animus | set | recipients:
+ animus |
| 2015-10-24 23:03:29 | animus | set | messageid: <1445727809.94.0.696138695468.issue25471@psf.upfronthosting.co.za> |
| 2015-10-24 23:03:29 | animus | link | issue25471 messages |
| 2015-10-24 23:03:29 | animus | create | |
|