def _read_compat(self): fd_set = types.mkfdset2(self.fileno()) lib.snmp_sess_read2(self.sessp, byref(fd_set)) types.rmfdset2(fd_set)
def _timeout_compat(self, tv, block): fd_max = ctypes.c_int() fd_set = types.mkfdset2(self.fileno()) lib.snmp_sess_select_info2(self.sessp, byref(fd_max), byref(fd_set), byref(tv), byref(block)) types.rmfdset2(fd_set)