我刚刚从http://www.epx.com.br/pysctp/安装了 pysctp ,但我无法让基本示例正常工作。我可能做错了什么?
我在 Red Hat Linux 上。
Python 2.7.2 (default, Oct 25 2011, 10:11:43)
[GCC 4.1.2 20070626 (Red Hat 4.1.2-14)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import socket
>>> import sctp
>>> sk = sctp.sctpsocket_tcp(socket.AF_INET)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/local/python2.7/lib/python2.7/site-packages/sctp.py", line 1644, in __init__
sctpsocket.__init__(self, family, TCP_STYLE, sk)
File "/usr/local/python2.7/lib/python2.7/site-packages/sctp.py", line 1016, in __init__
self.events = event_subscribe(self)
File "/usr/local/python2.7/lib/python2.7/site-packages/sctp.py", line 623, in __init__
self.__dict__.update(self.container._get_events())
File "/usr/local/python2.7/lib/python2.7/site-packages/sctp.py", line 1356, in _get_events
return _sctp.get_events(self._sk.fileno())
IOError: [Errno 22] Invalid argument