[issue7523] add SOCK_NONBLOCK and SOCK_CLOEXEC to socket module

Vetoshkin Nikita report at bugs.python.org
Wed Oct 13 22:49:52 CEST 2010


Vetoshkin Nikita <nikita.vetoshkin at gmail.com> added the comment:

Here's what strace on FAIL shows (print "in alarm_handler" added)

alarm(2)                                = 0
poll([{fd=3, events=POLLIN}], 1, 5000)  = ? ERESTART_RESTARTBLOCK (To be restarted)
--- SIGALRM (Alarm clock) @ 0 (0) ---
rt_sigreturn(0xffffffff)                = -1 EINTR (Interrupted system call)
accept4(3, 0x7fffa94c4780, [16], 0)     = -1 EAGAIN (Resource temporarily unavailable)
poll([{fd=3, events=POLLIN}], 1, 2999)  = 0 (Timeout)
accept4(3, 0x7fffa94c4780, [16], 0)     = -1 EAGAIN (Resource temporarily unavailable)
write(1, "in alarm_handler\n", 17)      = 17
alarm(0)                                = 0

Here's on OK:

alarm(2)                                = 0
poll([{fd=3, events=POLLIN}], 1, 5000)  = ? ERESTART_RESTARTBLOCK (To be restarted)
--- SIGALRM (Alarm clock) @ 0 (0) ---
rt_sigreturn(0xffffffff)                = -1 EINTR (Interrupted system call)
write(1, "in alarm_handler\n", 17)      = 17
alarm(0)

For some reason does another trip through BEGIN_SELECT_LOOP() macro

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue7523>
_______________________________________


More information about the Python-bugs-list mailing list