IDA 7.7 list index out of range
LOVECHEN opened this issue · 1 comments
C:\IDA\python\go_parser.py: list index out of range
Traceback (most recent call last):
File "C:\IDA\python\3\ida_idaapi.py", line 580, in IDAPython_ExecScript
exec(code, g)
File "C:/IDA/python/go_parser.py", line 56, in
main()
File "C:/IDA/python/go_parser.py", line 50, in main
type_parser.build_all_types()
File "C:\IDA\python\types_builder.py", line 51, in build_all_types
self._parse_extra_types()
File "C:\IDA\python\types_builder.py", line 84, in _parse_extra_types
self.parse_type(type_addr=target_type_addr)
File "C:\IDA\python\types_builder.py", line 100, in parse_type
rtype.parse()
File "C:\IDA\python\types_builder.py", line 254, in parse
idc.set_cmt(self.addr + 2*ADDR_SZ + 7, f"kind: {self.get_kind()}", 0)
File "C:\IDA\python\types_builder.py", line 305, in get_kind
return self.TYPE_KINDS[self.kind]
IndexError: list index out of range
在使用懒汉方式的单例模式,就会出现这个错误,应该是一个BUG
var ins *singleton
var mu sync.Mutex
func GetIns() *singleton {
if ins == nil {
mu.Lock()
if ins != nil {
return &singleton{}
}
mu.Unlock()
}
return ins
}