Eeschema: schematic files might be saved having a wrong file extension
Bug #1122212 reported by
Antia Puentes
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
KiCad |
Fix Released
|
Undecided
|
Antia Puentes |
Bug Description
It is possible to save a file in schematic having a wrong file extension or not file extension at all.
Steps to reproduce:
1. Open schematic
2. Menu: File -> Save current sheet as
3. Type a filename having an extension different to '.sch' or not extension at all.
Output:
The file is saved but it is not possible to open it anymore because the Eeschema Open dialog filters the files by the '.sch' extension.
Changed in kicad: | |
assignee: | nobody → Antia Puentes (apuentes) |
Changed in kicad: | |
status: | New → Fix Committed |
To post a comment you must log in.
The patch adds the appropriate file extension before saving if the file has an incorrect extension or not extension at all. FRAME:: SaveEEFile function.
It also refactors the SCH_EDIT_
Once the correct extension is added, if a file with the same filename already exists it creates the .bak file before saving the new file. This was needed because the dialog class used, wxFileDialog, doesn't check that the file has the correct extension, although you set the wildcard.