Merge branch 'GP-0_ryanmkurtz_PR-9304_pgalbraith_fix_9303-npe'

This commit is contained in:
Ryan Kurtz
2026-06-24 13:36:35 -04:00
@@ -69,7 +69,14 @@ public class ForceUnionAction extends AbstractDecompilerAction {
}
Varnode vn = tokenAtCursor.getVarnode();
if (vn != null) {
DataType dt = vn.getHigh().getDataType();
// Some Varnodes -- volatile-memory loads in particular -- never get
// a HighVariable assigned during decompile, so getHigh() can be null.
// Same guard pattern as typeIsUnionRelated below.
HighVariable high = vn.getHigh();
if (high == null) {
return null;
}
DataType dt = high.getDataType();
if (dt instanceof TypeDef) {
dt = ((TypeDef) dt).getBaseDataType();
}