编写插件:当我启动一个线程时,IDA-Pro崩溃了

2024-04-19 11:12:37 发布

您现在位置:Python中文网/ 问答频道 /正文

当我尝试启动线程到run方法时,IDA pro会崩溃,有什么想法吗??在

在ida中运行线程有什么限制吗?因为我在文档中找不到任何东西,writing plugin ida。在

import idaapi
from threading import Thread
import time

class Listener(Thread):
    def __init__(self):
        Thread.__init__(self)

    def run(self):
        time.sleep(3)

class myplugin_t(idaapi.plugin_t):
    flags = idaapi.PLUGIN_UNL

    def init(self):
        return idaapi.PLUGIN_OK

    def run(self, arg):
        t1 = Listener();
        t1.start();
        t1.join();

    def term(self):
        pass

def PLUGIN_ENTRY():
    return myplugin_t()

PS:我用c++编写插件时也发现了同样的问题


Tags: runimportselftimeinitdef线程plugin