macdivert.py 文件源码

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

项目:wireless-network-reproduction 作者: FinalTheory 项目源码 文件源码
def _load_libc(self):
        self._libc = cdll.LoadLibrary('libc.dylib')
        # set the types of parameters
        for func_name, argtypes in self.libc_argtypes.items():
            if not hasattr(self._libc, func_name):
                raise RuntimeError("Not a valid libC library")
            setattr(getattr(self._libc, func_name), "argtypes", argtypes)
        # set the types of return value
        for func_name, restype in self.libc_restypes.items():
            setattr(getattr(self._libc, func_name), "restype", restype)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号