mirror of
https://github.com/NationalSecurityAgency/ghidra.git
synced 2025-10-03 17:59:46 +02:00
GP-3162: refresh bool->enum
This commit is contained in:
parent
a9baf9f6d8
commit
15c4345d71
116 changed files with 376 additions and 266 deletions
|
@ -19,6 +19,7 @@ import ghidra.app.plugin.core.debug.DebuggerCoordinates;
|
|||
import ghidra.app.script.GhidraScript;
|
||||
import ghidra.app.services.*;
|
||||
import ghidra.dbg.DebuggerObjectModel;
|
||||
import ghidra.dbg.DebuggerObjectModel.RefreshBehavior;
|
||||
import ghidra.dbg.target.TargetObject;
|
||||
import ghidra.dbg.target.TargetRegisterBank;
|
||||
import ghidra.dbg.util.PathMatcher;
|
||||
|
@ -52,7 +53,7 @@ public class RefreshRegistersScript extends GhidraScript {
|
|||
// If you know the names of the registers to read
|
||||
bank.readRegistersNamed("rax", "rbx").get();
|
||||
// Values are coupled to elements, so we can also just refresh them to re-read all
|
||||
bank.fetchElements(true).get();
|
||||
bank.fetchElements(RefreshBehavior.REFRESH_ALWAYS).get();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -76,7 +77,7 @@ public class RefreshRegistersScript extends GhidraScript {
|
|||
for (TargetRegisterBank bank : banks) {
|
||||
// Now do the same to the bank as before
|
||||
bank.invalidateCaches().get();
|
||||
bank.fetchElements(true).get();
|
||||
bank.fetchElements(RefreshBehavior.REFRESH_ALWAYS).get();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue