sanyaade-g2g-repos / grafx2

Automatically exported from code.google.com/p/grafx2
0 stars 0 forks source link

Save/save as over existing (current) file fails #537

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
1. Open a file
2. Make some changes
3. Attempt to save, or 'save as' with the original filename
4. sometimes) The screen flashes red and the file is not overwritten.

I understand that the flashing red is supposed to indicate a problem with 
saving. However I've checked that all the likely causes (file doesn't belong to 
me, I don't have write permissions, or the directory that the file is in was 
moved) are not present, and the problem still occurs.

My current workaround is to save under an altered name and then save as the 
original name -- for example, save 'fluit9.gif' and then save 'fruit9.gif'.

The fact that this works suggests to me that some internal structure is only 
getting initialized when the 'save' operation uses a 'new' filename, not when 
it reuses the old one.

You should also know that temporarily selecting another filename, and then 
switching back to the original (before confirming the save) does not work 
around the problem -- the workaround seems to need me to ACTUALLY save a file, 
not just change the filename.

Platform info: 
I am running GrafX2 SVN r2062 on Arch Linux x86_64.

Original issue reported on code.google.com by fintic...@gmail.com on 4 Aug 2013 at 11:49

GoogleCodeExporter commented 9 years ago
In "Options", page "File Selector", please set "Backup = NO" and retry.
This will tell us if the failure is in the backup (it renames older file, 
adding .BAK file extension) or actual saving.
If the problem still happens, can you try removing the line that says 
"setvbuf(file, NULL, _IOFBF, 64*1024);" in function Save_GIF() of fileformats.c 
? (this line is present for every file format, remove the one for the format 
that you're testing)

Original comment by yrizoud on 7 Aug 2013 at 1:08