protocol.py 文件源码

python
阅读 30 收藏 0 点赞 0 评论 0

项目:SameKeyProxy 作者: xzhou 项目源码 文件源码
def set_sock_keepalive(sock):
    if Pyro.config.PYRO_SOCK_KEEPALIVE:
        try:
            sock.setsockopt ( socket.SOL_SOCKET, socket.SO_KEEPALIVE, 1 )
        except:
            Pyro.config.PYRO_SOCK_KEEPALIVE=0    # it didn't work--disable keepalives.


#------ PYRO: adapter (default Pyro wire protocol)
#------ This adapter is for protocol version 4 ONLY
# Future adapters could be downwards compatible and more flexible.
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号