Opened 7 years ago

Closed 7 years ago

#5104 defect closed duplicate (duplicate)

iocpreactor doesn't work with 64-bit Python

Reported by: Wolfgang Owned by:
Priority: high Milestone:
Component: core Keywords: iocp
Cc: ivank Branch:
Author: tds333@gmail.com

Description

I tried the version at: http://www.lfd.uci.edu/~gohlke/pythonlibs/

and a self compile version (VC9 64bit SDK).

But there is an error in the ICOP reactor code with socket handling:

File "D:\svn\Python_Windows64bit\Lib\site-packages\twisted\internet\iocpreactor\reactor.py", line 118, in

_callEventCallback

evt.callback(rc, bytes, evt)

File "D:\svn\Python_Windows64bit\Lib\site-packages\twisted\internet\iocpreactor\tcp.py", line 585, in cbAc

cept

self.handleAccept(rc, evt)

File "D:\svn\Python_Windows64bit\Lib\site-packages\twisted\internet\iocpreactor\tcp.py", line 602, in hand

leAccept

struct.pack('I', self.socket.fileno()))

File "D:\svn\Python_Windows64bit\lib\socket.py", line 224, in meth

return getattr(self._sock,name)(*args)

socket.error: [Errno 10014] The system detected an invalid pointer address in attempting to use a pointer argument in a call

Use Python 2.7.1 64bit Windows, ICOP reactor, simple webserver with one Resource. Twisted 11.0 Release

Change History (2)

comment:1 Changed 7 years ago by Wolfgang

changing struct.pack('I', self.socket.fileno())) to struct.pack('Q', self.socket.fileno())) fixes the problem for Win 64bit

duplicate of #4669 sorry didn't find that one

comment:2 Changed 7 years ago by ivank

Cc: ivank added
Keywords: iocp added; Windows 64bit icop removed
Resolution: duplicate
Status: newclosed
Summary: Windows 64bit, ICOP reactor don't work, Socket erroriocpreactor doesn't work with 64-bit Python

I saw a very similar exception when I tried it 1.5 years ago.

Note: See TracTickets for help on using tickets.