GP-0 Ensure Program.getCompiler() returns "unknown" instead of null

This commit is contained in:
ghidra1 2023-12-05 07:51:48 -05:00
parent 53275c92f8
commit 6242fda158
3 changed files with 5 additions and 3 deletions

View file

@ -911,11 +911,13 @@ public class DBTraceProgramView implements TraceProgramView {
@Override
public String getCompiler() {
return null;
// TODO: not yet implemented
return "unknown";
}
@Override
public void setCompiler(String compiler) {
// TODO: not yet implemented
throw new UnsupportedOperationException();
}

View file

@ -35,7 +35,7 @@ public class RustDemangler implements Demangler {
@Override
public boolean canDemangle(Program program) {
String name = program.getCompiler();
return name != null && name.contains("rustc");
return name.contains("rustc");
}
@Override

View file

@ -397,7 +397,7 @@ public class StubProgram implements Program {
@Override
public String getCompiler() {
throw new UnsupportedOperationException();
return "unknown";
}
@Override