Merge remote-tracking branch 'origin/GP-4045_dev747368_lock_sla_files'

(Closes #8866)
This commit is contained in:
Ryan Kurtz
2026-03-11 05:14:29 -04:00
28 changed files with 2188 additions and 679 deletions
@@ -27,6 +27,7 @@ import ghidra.app.CorePluginPackage;
import ghidra.app.context.ProgramActionContext;
import ghidra.app.context.ProgramContextAction;
import ghidra.app.plugin.PluginCategoryNames;
import ghidra.app.plugin.processors.sleigh.SleighLanguageDescription;
import ghidra.app.util.GenericHelpTopics;
import ghidra.app.util.HelpTopics;
import ghidra.framework.main.ApplicationLevelPlugin;
@@ -169,7 +170,7 @@ public class AboutProgramPlugin extends Plugin implements ApplicationLevelPlugin
metadata.put("Language Spec",
lDesc.getDefsFile() + (lav.isMismatch() ? lav.getVersionDisplay() : ""));
metadata.put("Processor Spec", lDesc.getSpecFile().getAbsolutePath());
metadata.put("Sleigh Spec", lDesc.getSlaFile().getAbsolutePath() + "spec");
metadata.put("Sleigh Spec", lDesc.getLanguageFile().getSlaSpecFile().getAbsolutePath());
}
if (lav.compilerSpec != null) {
metadata.put("Compiler Spec",
@@ -27,6 +27,7 @@ import java.util.regex.Pattern;
import generic.jar.ResourceFile;
import ghidra.app.cmd.comments.AppendCommentCmd;
import ghidra.app.plugin.processors.sleigh.SleighLanguageDescription;
import ghidra.app.util.bin.format.dwarf.attribs.DWARFAttributeValue;
import ghidra.app.util.bin.format.dwarf.attribs.DWARFNumericAttribute;
import ghidra.app.util.bin.format.dwarf.expression.DWARFExpressionException;
@@ -170,8 +170,12 @@ public class ProgramOpener {
// we don't care, the task has been cancelled
}
catch (LanguageNotFoundException e) {
Msg.showError(this, null, "Error Opening " + filename,
e.getMessage() + "\nPlease contact the Ghidra team for assistance.");
String msg = e.getMessage() + "\n";
if (e.getCause() != null) {
msg += e.getCause().getMessage() + "\n";
}
msg += "Please contact the Ghidra team for assistance.";
Msg.showError(this, null, "Error Opening " + filename, msg);
}
catch (Exception e) {
if (domainFile.isInWritableProject() && (e instanceof IOException)) {