27

When I attempt to save an image with GIMP, the save fails and GIMP displays an error message Error while saving <filename>. Could not save image:

enter image description here

The issue happens when I right click an image and select Open With ▸ GIMP.app. Then, after editing, I choose Overwirte existing file. Worse, GIMP manages to truncate existing files to 0 (during an overwrite of an existing file), so the original file is lost.

Upon exiting GIMP, I can save the XCF file.

The problem started recently (perhaps since the install of the latest GIMP). The previosu two or three years were fine.

My setup is Mac OS X 10.8.5 (fully patched), and GIMP is 2.8.10 (which I believe is the latest). GIMP is installed in /Applications (just like past versions). I also tried deleting GIMP from the command line and reinstalling it.

Does anyone know why GIMP cannot save files?

2 Answers 2

35

The problem is with png only. When gimp saves to jpg, tiff or something else there aren't any error.

There is a bug for this https://bugs.archlinux.org/task/35363

I tried the workaround from this link and it helped me

Menu - Image - Mode - Convert to Color Profile ...

Then just click "Convert" to convert it to "RGB workspace (sRGB built-in)"

Now exporting to PNG just works flawlessly.

4
  • I found that I could start with a TIFF, and still not be able to save until the conversion. I think there's more going on that just existing malformed PNGs that need converting.
    – jww
    Commented Jul 13, 2014 at 7:36
  • Thanks! However these steps are required for every single .png-file you are trying to modify/save. Does anyone knows a 'universal' solution for all png?
    – vir us
    Commented Aug 27, 2014 at 23:41
  • fantastic, works like a charm!!! :)
    – nburk
    Commented Nov 4, 2014 at 21:53
  • I had to convert to a GIF to get it to work with transparency. Commented May 29, 2015 at 13:26
5

A permanent fix is to set a sRBG profile in Preferences" -> "Color Management" by selecting an .icc file.

Need an .icc file? On OSX (Mavericks):

"System Preferences" -> "Displays" then select a profile on the left, then click Button "Open Profile". This opens the profile in "ColorSync Utility". "Save as ..." and pick a location for you .icc file.

OR:

Open "ColorSync Utility", then under "Profiles" select one, then click "Open" to the right. Finally "Save as ..." again.

When opening a PNG with an embedded profile you will now be prompted if you wan to convert to your selected Profile. If you select "Keep" saving will not work and leave you with a broken, zero bytes file. So chose "Convert

Enjoy saving PNGs in GIMP.

0

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .