A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2011-February/108141.html below:

[Python-Dev] [Python-checkins] r88484 - in python/branches/py3k: Lib/test/subprocessdata/fd_status.py Lib/test/test_subprocess.py Misc/NEWS

[Python-Dev] [Python-checkins] r88484 - in python/branches/py3k: Lib/test/subprocessdata/fd_status.py Lib/test/test_subprocess.py Misc/NEWS [Python-Dev] [Python-checkins] r88484 - in python/branches/py3k: Lib/test/subprocessdata/fd_status.py Lib/test/test_subprocess.py Misc/NEWSVictor Stinner victor.stinner at haypocalc.com
Tue Feb 22 01:02:58 CET 2011
Le 21/02/2011 22:55, antoine.pitrou a écrit :
> Author: antoine.pitrou
> Date: Mon Feb 21 22:55:48 2011
> New Revision: 88484
>
> Log:
> Issue #10826: Prevent sporadic failure in test_subprocess on Solaris due
> to open door files.
>    
>   if __name__ == "__main__":
> -    print(','.join(str(fd) for fd in range(0, _MAXFD) if isopen(fd)))
> +    fds = []
> +    for fd in range(0, _MAXFD):
> +        try:
> +            st = os.fstat(fd)
> +        except OSError as e:
> +            if e.errno == errno.EBADF:
> +                continue
> +            raise
> +        # Ignore Solaris door files
> +        if st.st_mode&  0xF000 != 0xd000:
> +            fds.append(fd)
>    

Are 0xF000 and 0xD000 constants specific to Solaris? If yes, you may 
only skip these files on Solaris, not on other OSes.

Victor
More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4