Failing to replace a file (e.g. ICO cannot be >255px) will end up deleting the original file
Bug #1888141 reported by
Stdedos
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Pinta |
Triaged
|
Medium
|
Unassigned |
Bug Description
Repro:
1. Save a file with name ~/a.ico
2. Load a >256x256px file
3. Save the file with name ~/a.ico
Expected:
File cannot be saved, file ~/a.ico is not touched
Actual:
File cannot be saved, file ~/a.ico is removed
To post a comment you must log in.
Confirmed.
It seems to be an issue with an error occurring in Pixbuf.Save(). In the specific case of .ico files we could check the size ahead of time instead of waiting to catch an exception, but more generally it seems like we might need to save to a temp file or something like that first to be on the safe side.