mirror of
https://github.com/NationalSecurityAgency/ghidra.git
synced 2025-10-04 18:29:37 +02:00
GP-668: PyDev debugger now stays on breakpoints appropriately (fixes
#2713)
This commit is contained in:
parent
fef756c967
commit
606eecfa82
1 changed files with 5 additions and 1 deletions
|
@ -218,8 +218,12 @@ public class GhidraPythonInterpreter extends InteractiveInterpreter {
|
|||
InetAddress localhost = InetAddress.getLocalHost();
|
||||
new Socket(localhost, PyDevUtils.PYDEV_REMOTE_DEBUGGER_PORT).close();
|
||||
Msg.info(this, "Python debugger found");
|
||||
exec("import pydevd; pydevd.settrace(host=\"" + localhost.getHostName() +
|
||||
StringBuilder dbgCmds = new StringBuilder();
|
||||
dbgCmds.append("import pydevd;");
|
||||
dbgCmds.append("pydevd.threadingCurrentThread().__pydevd_main_thread = True;");
|
||||
dbgCmds.append("pydevd.settrace(host=\"" + localhost.getHostName() +
|
||||
"\", port=" + PyDevUtils.PYDEV_REMOTE_DEBUGGER_PORT + ", suspend=False);");
|
||||
exec(dbgCmds.toString());
|
||||
Msg.info(this, "Connected to a python debugger.");
|
||||
}
|
||||
catch (IOException e) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue