GP-4057 Corrected ProjectLocator bug and corrected use of various

directory preferences to varefy directory existance.
This commit is contained in:
ghidra1 2023-11-20 16:35:20 -05:00
parent bb4a9ccbb1
commit af160d946d
14 changed files with 66 additions and 30 deletions

View file

@ -401,7 +401,10 @@ public class SpecExtensionPanel extends JPanel {
private static File getStartingDir() {
String lastDirectoryPath = Preferences.getProperty(LAST_EXPORT_DIRECTORY);
if (lastDirectoryPath != null) {
return new File(lastDirectoryPath);
File dir = new File(lastDirectoryPath);
if (dir.isDirectory()) {
return dir;
}
}
return new File(System.getProperty("user.home"));