Gtk crashes if trying to load SVG only icon without SVG gdk-pixbuf loader enabled
(thanks @otte for helping out debugging this)
If there is a gresource file containing SVG icons, and we try to load such an icon without available fallback on a system without a SVG gdk-pixbuf loader installed or enabled, we'll crash with the following backtrace:
#0 0x00007ffff71be2b5 in __strlen_avx2 () at /lib64/libc.so.6
#1 0x00007ffff7460eba in () at /lib64/libgio-2.0.so.0
#2 0x00007ffff746154f in g_resource_get_info () at /lib64/libgio-2.0.so.0
#3 0x00007ffff7461c74 in g_resources_get_info () at /lib64/libgio-2.0.so.0
#4 0x00007ffff75ae7ef in _gdk_pixbuf_new_from_resource_try_pixdata
(resource_path=resource_path@entry=0x0)
at ../gdk-pixbuf/gdk-pixbuf-io.c:1681
#5 0x00007ffff75ae8f4 in gdk_pixbuf_new_from_resource
(resource_path=0x0, error=0x4cf890) at ../gdk-pixbuf/gdk-pixbuf-io.c:1732
#6 0x00007ffff7a9ad98 in () at /lib64/libgtk-3.so.0
#7 0x00007ffff7a9e248 in gtk_icon_info_load_icon () at /lib64/libgtk-3.so.0
#8 0x00007ffff7a9e4b4 in gtk_icon_theme_load_icon_for_scale ()
at /lib64/libgtk-3.so.0
Although a strange situation, it should be handled more gracefully by not crashing.
Test case available here: no-svg-loader-test-case.tar.xz