After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 631728 - Crash or Gtk-CRITICAL on File->Open
Crash or Gtk-CRITICAL on File->Open
Status: RESOLVED FIXED
Product: GIMP
Classification: Other
Component: User Interface
2.6.11
Other Linux
: Normal major
: 2.6
Assigned To: GIMP Bugs
GIMP Bugs
Depends on:
Blocks:
 
 
Reported: 2010-10-09 06:34 UTC by my.somewhat.lengthy.loginname
Modified: 2010-10-18 16:30 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Proposed patch (563 bytes, patch)
2010-10-16 01:12 UTC, my.somewhat.lengthy.loginname
none Details | Review

Description my.somewhat.lengthy.loginname 2010-10-09 06:34:40 UTC
Since approximately version 2.6.8 GIMP crashes each time I use File -> Open. That is still the case with gimp 2.6.11 and gtk+ 2.22.0.

All of the time, File -> Open worked flawlessly in other programs that use the gtk+ file chooser (Firefox, leafpad, epdfview, etc).

So far I had compiled gtk+ with the option "--enable-debug=no". I finally recompiled gtk+ with the default (which is "--enable-debug=minimum"). Now File -> Open brings up the gtk+ filechooser in gimp, together with the following message in the console window from where I started gimp:

(gimp:1081): Gtk-CRITICAL **: IA__gtk_icon_info_load_icon: assertion `icon_info != NULL' failed

If that is relevant: I have no icon theme set, so everything should use the gtk+ stock icons.
Comment 1 my.somewhat.lengthy.loginname 2010-10-09 07:03:16 UTC
Compiling gtk+ with "--enable-debug=yes" is not more informative; it leads to the same error message.
Comment 2 my.somewhat.lengthy.loginname 2010-10-16 01:12:10 UTC
Created attachment 172474 [details] [review]
Proposed patch

Suggested patch that fixes the issue. Short and self-explaining.
Comment 3 Sven Neumann 2010-10-18 15:51:06 UTC
This is already fixed in trunk. I have now backported the fix to the stable branch:

Author: Michael Natterer <mitch@gimp.org>
Date:   Tue Sep 22 20:25:11 2009 +0200

    Guard against g_file_info_get_icon() returning NULL
    
    It can return NULL, but should not for a proper gvfs backend; add a
    returning NULL.
    (cherry picked from commit 295f345b2eca4b224f51192632e0bc2060c6e07d)
Comment 4 Sven Neumann 2010-10-18 15:54:03 UTC
Actually, this fixes the problem of GVFS returning a NULL pointer, but not the problem of a missing icon. Will commit a fix for this later...
Comment 5 Sven Neumann 2010-10-18 16:30:54 UTC
Fixed in both branches:

commit 1130e8c8908c7d011948bac9ae65c7f57b18e8dd
Author: Sven Neumann <sven@gimp.org>
Date:   Mon Oct 18 18:28:57 2010 +0200

    Bug 631728 - Crash or Gtk-CRITICAL on File->Open
    
    Check return value of gtk_icon_theme_lookup_by_gicon() before using it.