File system-config-printer-bnc555569-kde-crash.patch of Package system-config-printer

Index: system-config-printer-1.1.12/system-config-printer.py
===================================================================
--- system-config-printer-1.1.12.orig/system-config-printer.py
+++ system-config-printer-1.1.12/system-config-printer.py
@@ -1469,15 +1469,18 @@ class GUI(GtkGUI, monitor.Watcher):
 
                 if def_emblem:
                     (w, h) = gtk.icon_size_lookup (gtk.ICON_SIZE_DIALOG)
-                    default_emblem = theme.load_icon (def_emblem, w/2, 0)
-                    copy = pixbuf.copy ()
-                    default_emblem.composite (copy, 0, 0,
-                                              copy.get_width (),
-                                              copy.get_height (),
-                                              0, 0,
-                                              1.0, 1.0,
-                                              gtk.gdk.INTERP_NEAREST, 255)
-                    pixbuf = copy
+                    try:
+                        default_emblem = theme.load_icon (def_emblem, w/2, 0)
+                        copy = pixbuf.copy ()
+                        default_emblem.composite (copy, 0, 0,
+                                                  copy.get_width (),
+                                                  copy.get_height (),
+                                                  0, 0,
+                                                  1.0, 1.0,
+                                                  gtk.gdk.INTERP_NEAREST, 255)
+                        pixbuf = copy
+                    except gobject.GError:
+                        debugprint ("No %s icon available" % def_emblem)
 
                 if emblem:
                     (w, h) = gtk.icon_size_lookup (gtk.ICON_SIZE_DIALOG)
openSUSE Build Service is sponsored by