Skip to content

Ghidra is a software reverse engineering (SRE) framework

GP-1 Corrected regression to SymbolDB refresh from GP-6634 change

ghidra1b1f9b648bbc4
diff --git a/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/database/symbol/SymbolDB.java b/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/database/symbol/SymbolDB.java
index 6aa4db5240..54bde44ee7 100644
--- a/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/database/symbol/SymbolDB.java
+++ b/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/database/symbol/SymbolDB.java
@@ -94,7 +94,12 @@ public abstract class SymbolDB extends DbObject implements Symbol {
record = rec;
Address newAddress = symbolMgr.getAddressMap()
.decodeAddress(rec.getLongValue(SymbolDatabaseAdapter.SYMBOL_ADDR_COL));
- return address.equals(newAddress);
+ boolean isAddrSame = address.equals(newAddress);
+ address = newAddress;
+ // NOTE: If isAddrSame is not true, the symbol address changed which implies this
+ // symbol was deleted and the key re-used. It is important to note this instance
+ // is not the same symbol as the previous record state and should not be used.
+ return isAddrSame;
}
return false;
}