[Python-Dev] Socket timeout: reset timeout at each successful syscall? (original) (raw)

Antoine Pitrou solipsis at pitrou.net
Sat Apr 4 13:27:25 CEST 2015


On Fri, 3 Apr 2015 13:56:44 +0200 Victor Stinner <victor.stinner at gmail.com> wrote:

The problem is that the socket.sendall() method may require multiple syscalls. In this case, does the timeout count for the total time or only for a single syscall? Asked differently: should we reset the timeout each time a syscall succeed?

From a user's point of view, it should count for the total time, IMO. If people want a timeout for each syscall, they should call send() iteratively.

Regards

Antoine.



More information about the Python-Dev mailing list