diff --git a/Ghidra/Features/Decompiler/ghidra_scripts/classrecovery/RTTIWindowsClassRecoverer.java b/Ghidra/Features/Decompiler/ghidra_scripts/classrecovery/RTTIWindowsClassRecoverer.java index 31e5776379..ab818f4ac1 100644 --- a/Ghidra/Features/Decompiler/ghidra_scripts/classrecovery/RTTIWindowsClassRecoverer.java +++ b/Ghidra/Features/Decompiler/ghidra_scripts/classrecovery/RTTIWindowsClassRecoverer.java @@ -236,9 +236,9 @@ public class RTTIWindowsClassRecoverer extends RTTIClassRecoverer { // } // // private void runRTTIAnalyzer() throws Exception { -//// Analyzer analyzer = new RttiAnalyzer(); -//// analyzer.added(program, program.getAddressFactory().getAddressSet(), monitor, -//// new MessageLog()); + //// Analyzer analyzer = new RttiAnalyzer(); / analyzer.added(program, + /// program.getAddressFactory().getAddressSet(), monitor, / + /// new MessageLog()); // } // // /** diff --git a/Ghidra/Features/Decompiler/ghidra_scripts/classrecovery/RecoveredClassHelper.java b/Ghidra/Features/Decompiler/ghidra_scripts/classrecovery/RecoveredClassHelper.java index 80f25922cc..aebe32d811 100644 --- a/Ghidra/Features/Decompiler/ghidra_scripts/classrecovery/RecoveredClassHelper.java +++ b/Ghidra/Features/Decompiler/ghidra_scripts/classrecovery/RecoveredClassHelper.java @@ -5698,8 +5698,27 @@ public class RecoveredClassHelper { if (!areVftablesInSameClass(vftableReferenceList)) { recoveredClass.addIndeterminateInline(indeterminateFunction); indeterminateIterator.remove(); + continue; } } + // Next try identifying non-constructor/destructor but contains inline + // using decompiler return type + DataType decompilerReturnType = + decompilerUtils.getDecompilerReturnType(indeterminateFunction); + + if (decompilerReturnType != null) { + + String returnDataName = decompilerReturnType.getDisplayName(); + if (returnDataName.contains("*") && + !isFidFunction(indeterminateFunction)) { + continue; + } + if (returnDataName.equals("void")) { + continue; + } + recoveredClass.addIndeterminateInline(indeterminateFunction); + indeterminateIterator.remove(); + } } } } @@ -6293,7 +6312,7 @@ public class RecoveredClassHelper { // otherwise, use pcode info to figure out if inlined constructor or destructor //If not already, make function a this call - makeFunctionThiscall(inlineFunction); + // makeFunctionThiscall(inlineFunction); List loads = getLoadPcodeOpPairs(inlineFunction); List stores = getStorePcodeOpPairs(inlineFunction);