mirror of
https://github.com/NationalSecurityAgency/ghidra.git
synced 2025-10-04 18:29:37 +02:00
GP-0: Fix TraceRmi tests.
This commit is contained in:
parent
ca816dee61
commit
c956b2da2f
1 changed files with 12 additions and 13 deletions
|
@ -309,8 +309,12 @@ public class TraceRmiTarget extends AbstractTarget {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean isSupportsFocus() {
|
public boolean isSupportsFocus() {
|
||||||
return trace.getObjectManager()
|
TargetObjectSchema schema = trace.getObjectManager().getRootSchema();
|
||||||
.getRootSchema()
|
if (schema == null) {
|
||||||
|
Msg.warn(this, "Checked for focus support before root schema is available");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
return schema
|
||||||
.getInterfaces()
|
.getInterfaces()
|
||||||
.contains(TargetFocusScope.class) &&
|
.contains(TargetFocusScope.class) &&
|
||||||
!connection.getMethods().getByAction(ActionName.ACTIVATE).isEmpty();
|
!connection.getMethods().getByAction(ActionName.ACTIVATE).isEmpty();
|
||||||
|
@ -938,26 +942,21 @@ public class TraceRmiTarget extends AbstractTarget {
|
||||||
}
|
}
|
||||||
|
|
||||||
protected Set<TraceBreakpointKind> computeSupportedBreakpointKinds() {
|
protected Set<TraceBreakpointKind> computeSupportedBreakpointKinds() {
|
||||||
MatchedMethod breakHwExec = matches.getBest(BREAK_HW_EXEC, null, null);
|
|
||||||
MatchedMethod breakSwExec = matches.getBest(BREAK_SW_EXEC, null, null);
|
|
||||||
MatchedMethod breakRead = matches.getBest(BREAK_READ, null, null);
|
|
||||||
MatchedMethod breakWrite = matches.getBest(BREAK_WRITE, null, null);
|
|
||||||
MatchedMethod breakAccess = matches.getBest(BREAK_ACCESS, null, null);
|
|
||||||
|
|
||||||
Set<TraceBreakpointKind> result = new HashSet<>();
|
Set<TraceBreakpointKind> result = new HashSet<>();
|
||||||
if (breakHwExec != null) {
|
RemoteMethodRegistry methods = connection.getMethods();
|
||||||
|
if (!methods.getByAction(ActionName.BREAK_HW_EXECUTE).isEmpty()) {
|
||||||
result.add(TraceBreakpointKind.HW_EXECUTE);
|
result.add(TraceBreakpointKind.HW_EXECUTE);
|
||||||
}
|
}
|
||||||
if (breakSwExec != null) {
|
if (!methods.getByAction(ActionName.BREAK_SW_EXECUTE).isEmpty()) {
|
||||||
result.add(TraceBreakpointKind.SW_EXECUTE);
|
result.add(TraceBreakpointKind.SW_EXECUTE);
|
||||||
}
|
}
|
||||||
if (breakRead != null) {
|
if (!methods.getByAction(ActionName.BREAK_READ).isEmpty()) {
|
||||||
result.add(TraceBreakpointKind.READ);
|
result.add(TraceBreakpointKind.READ);
|
||||||
}
|
}
|
||||||
if (breakWrite != null) {
|
if (!methods.getByAction(ActionName.BREAK_WRITE).isEmpty()) {
|
||||||
result.add(TraceBreakpointKind.WRITE);
|
result.add(TraceBreakpointKind.WRITE);
|
||||||
}
|
}
|
||||||
if (breakAccess != null) {
|
if (!methods.getByAction(ActionName.BREAK_ACCESS).isEmpty()) {
|
||||||
result.add(TraceBreakpointKind.READ);
|
result.add(TraceBreakpointKind.READ);
|
||||||
result.add(TraceBreakpointKind.WRITE);
|
result.add(TraceBreakpointKind.WRITE);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue