Changeset d9b0936 in mod_gnutls
- Timestamp:
- Dec 2, 2019, 2:26:09 PM (3 years ago)
- Branches:
- asyncio, main, master, proxy-ticket
- Children:
- 4dfbedd
- Parents:
- fc8eefcd
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
test/https-test-client.py
rfc8eefcd rd9b0936 57 57 cert_log = b'Processed 1 client X.509 certificates...\n' 58 58 59 # Set the input to non-blocking mode 59 60 fd = in_stream.fileno() 60 61 fl = fcntl.fcntl(fd, fcntl.F_GETFL) 61 62 fcntl.fcntl(fd, fcntl.F_SETFL, fl | os.O_NONBLOCK) 63 64 # The poll object allows waiting for events on non-blocking IO 65 # channels. 62 66 poller = select.poll() 63 67 poller.register(fd) … … 65 69 run_loop = True 66 70 while run_loop: 67 # Critical: "event" is a bitwise OR of the POLL* constants 71 # The returned tuples are file descriptor and event, but 72 # we're only listening on one stream anyway, so we don't 73 # need to check it here. 68 74 for x, event in poller.poll(): 75 # Critical: "event" is a bitwise OR of the POLL* constants 69 76 if event & select.POLLIN or event & select.POLLPRI: 70 77 data = in_stream.read()
Note: See TracChangeset
for help on using the changeset viewer.