[issue32038] Add API to intercept socket.close()
Ben Darnell
report at bugs.python.org
Wed Nov 15 23:14:47 EST 2017
Ben Darnell <ben.darnell at gmail.com> added the comment:
It's worse than a resource leak - the same file descriptor number could be reused for a different file/socket, and then depending on the selector in use, you could see the data from a completely different connection.
I did see a bug like this years ago (in libcurl), although it's not a common problem. I'd use the proposed hook if it existed, but it seems like an intrusive solution to a rare issue.
----------
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue32038>
_______________________________________
More information about the Python-bugs-list
mailing list