Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Keepfd arg is backwards #1

@Posnet

Description

@Posnet

The keepfd arg is backwards for the python3 implementaion:

if keep_fd:
            return socket.fromfd(fd, family, typ, proto)
else:
            return socket.socket(family, typ, proto, fileno=fd)

see:
socket

... Unlike socket.fromfd(), fileno will return the same socket and not a duplicate ...

fromfd

Duplicate the file descriptor fd (an integer as returned by a file object’s fileno() method) and build a socket object ...

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions