Changeset 3fbe087 in mod_gnutls


Ignore:
Timestamp:
Dec 7, 2019, 3:24:22 PM (12 months ago)
Author:
Fiona Klute <fiona.klute@…>
Branches:
asyncio, master, proxy-ticket
Children:
a592762
Parents:
eb84747
Message:

Use os.set_blocking() instead of fiddling with file descriptor flags

File:
1 edited

Legend:

Unmodified
Added
Removed
  • test/mgstest/tests.py

    reb84747 r3fbe087  
    314314
    315315    """
    316     import fcntl
    317316    import os
    318317    import select
     
    322321    # Set the input to non-blocking mode
    323322    fd = in_stream.fileno()
    324     fl = fcntl.fcntl(fd, fcntl.F_GETFL)
    325     fcntl.fcntl(fd, fcntl.F_SETFL, fl | os.O_NONBLOCK)
     323    os.set_blocking(fd, False)
    326324
    327325    # The poll object allows waiting for events on non-blocking IO
Note: See TracChangeset for help on using the changeset viewer.