win32file._get_osfhandle

long = _get_osfhandle(fd)

Gets operating-system file handle associated with existing stream

Parameters

fd : int

File descriptor as returned by file.fileno()