mirror of
https://github.com/NationalSecurityAgency/ghidra.git
synced 2025-10-06 03:50:02 +02:00
PDB - corrected XML stack variable parse bug
This commit is contained in:
parent
b75a914b37
commit
d8e9384d4f
2 changed files with 6 additions and 1 deletions
|
@ -65,6 +65,7 @@ class ApplyStackVariables {
|
||||||
|
|
||||||
DataType dt = getDataType(member, log);
|
DataType dt = getDataType(member, log);
|
||||||
if (dt == null) {
|
if (dt == null) {
|
||||||
|
xmlParser.next();//stack variable number end tag
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -81,6 +81,7 @@ public class DefaultPdbMember extends PdbMember {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
if (kind == PdbKind.MEMBER) {
|
if (kind == PdbKind.MEMBER) {
|
||||||
|
// Strip bitfield data if present (see parseBitField method)
|
||||||
int bitFieldColonIndex = name.indexOf(':');
|
int bitFieldColonIndex = name.indexOf(':');
|
||||||
if (bitFieldColonIndex >= 0) {
|
if (bitFieldColonIndex >= 0) {
|
||||||
return name.substring(0, bitFieldColonIndex);
|
return name.substring(0, bitFieldColonIndex);
|
||||||
|
@ -118,7 +119,10 @@ public class DefaultPdbMember extends PdbMember {
|
||||||
}
|
}
|
||||||
|
|
||||||
private void parseBitField(String name) {
|
private void parseBitField(String name) {
|
||||||
int bitFieldColonIndex = name != null ? name.indexOf(':') : -1;
|
if (name == null || kind != PdbKind.MEMBER) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
int bitFieldColonIndex = name.indexOf(':');
|
||||||
if (bitFieldColonIndex >= 0) {
|
if (bitFieldColonIndex >= 0) {
|
||||||
|
|
||||||
isBitField = true;
|
isBitField = true;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue