Merge remote-tracking branch 'origin/caheckman_GT-2708' into Ghidra_9.0.2

This commit is contained in:
ghidravore 2019-04-02 18:36:30 -04:00
commit da7a2e2235
2 changed files with 8 additions and 4 deletions

View File

@ -76,8 +76,9 @@ public class DecompilerHoverProvider extends AbstractHoverProvider {
Varnode vn = token.getVarnode();
if (vn != null) {
if (vn.getHigh() instanceof HighGlobal) {
reference = vn.getAddress();
HighVariable highVar = vn.getHigh();
if (highVar instanceof HighGlobal) {
reference = highVar.getRepresentative().getAddress();
}
}

View File

@ -40,8 +40,7 @@ import ghidra.app.plugin.core.decompile.DecompileClipboardProvider;
import ghidra.program.model.address.*;
import ghidra.program.model.listing.Function;
import ghidra.program.model.listing.Program;
import ghidra.program.model.pcode.PcodeOp;
import ghidra.program.model.pcode.Varnode;
import ghidra.program.model.pcode.*;
import ghidra.program.util.ProgramLocation;
import ghidra.program.util.ProgramSelection;
import ghidra.util.*;
@ -419,6 +418,10 @@ public class DecompilerPanel extends JPanel implements FieldMouseListener, Field
}
}
HighVariable highVar = vn.getHigh();
if (highVar instanceof HighGlobal) {
vn = highVar.getRepresentative();
}
if (vn.isAddress()) {
Address addr = vn.getAddress();
if (addr.isMemoryAddress()) {