Fix "Duplicate scope id" error with undefined functions in decompiler

This commit is contained in:
caheckman 2020-10-06 15:40:58 -04:00
parent 7c0b21f0dc
commit e7b63fdab5

View file

@ -79,14 +79,15 @@ public class HighFunction extends PcodeSyntaxTree {
} }
/** /**
* Get the id with the associated function symbol, if it exists * Get the id with the associated function symbol, if it exists.
* @return the id or 0 otherwise * Otherwise return a dynamic id based on the entry point.
* @return the symbol id, or possibly a dynamic id
*/ */
public long getID() { public long getID() {
if (func instanceof FunctionDB) { if (func instanceof FunctionDB) {
return func.getSymbol().getID(); return func.getSymbol().getID();
} }
return 0; return func.getProgram().getSymbolTable().getDynamicSymbolID(func.getEntryPoint());
} }
/** /**