Fix crash when trying to import not .dxf or .dwg files

This commit is contained in:
Elvira Khabirova 2016-11-17 08:24:02 +03:00 committed by whitequark
parent 99d6f1f5b5
commit 6802a12a52

View File

@ -551,7 +551,10 @@ void SolveSpaceUI::MenuFile(int id) {
ImportDxf(importFile);
} else if(Extension(importFile) == "dwg") {
ImportDwg(importFile);
} else oops();
} else {
Error("Can't identify file type from file extension of "
"filename '%s'; try .dxf or .dwg.", importFile.c_str());
}
SS.GenerateAll(SolveSpaceUI::GENERATE_UNTIL_ACTIVE);
SS.ScheduleShowTW();