diff --git a/hplip-systray-dbus-exception.patch b/hplip-systray-dbus-exception.patch new file mode 100644 index 0000000..007fb0f --- /dev/null +++ b/hplip-systray-dbus-exception.patch @@ -0,0 +1,18 @@ +diff -up hplip-3.11.10/ui4/systemtray.py.dbus-exception hplip-3.11.10/ui4/systemtray.py +--- hplip-3.11.10/ui4/systemtray.py.dbus-exception 2011-10-25 15:59:53.360181865 +0100 ++++ hplip-3.11.10/ui4/systemtray.py 2011-10-25 16:03:55.294815114 +0100 +@@ -707,7 +707,13 @@ def run(read_pipe): + log.set_module("hp-systray(qt4)") + log.debug("PID=%d" % os.getpid()) + +- app = SystemTrayApp(sys.argv, read_pipe) ++ try: ++ app = SystemTrayApp(sys.argv, read_pipe) ++ except DBusException, e: ++ # No session bus ++ log.debug("Caught exception: %s" % e) ++ sys.exit(1) ++ + app.setQuitOnLastWindowClosed(False) # If not set, settings dlg closes app + + i = 0 diff --git a/hplip.spec b/hplip.spec index 3683fb3..d8c6015 100644 --- a/hplip.spec +++ b/hplip.spec @@ -1,7 +1,7 @@ Summary: HP Linux Imaging and Printing Project Name: hplip Version: 3.11.10 -Release: 6%{?dist} +Release: 7%{?dist} License: GPLv2+ and MIT Group: System Environment/Daemons Conflicts: system-config-printer < 0.6.132 @@ -26,6 +26,7 @@ Patch9: hplip-snmp-quirks.patch Patch10: hplip-discovery-method.patch Patch11: hplip-hpijs-marker-supply.patch Patch12: hplip-clear-old-state-reasons.patch +Patch13: hplip-systray-dbus-exception.patch Patch14: hplip-hpcups-sigpipe.patch Patch15: hplip-fax-ppd.patch Patch16: hplip-bad-low-ink-warning.patch @@ -206,6 +207,9 @@ mv prnt/drv/hpijs.drv.in{,.deviceIDs-drv-hpijs} # Clear old printer-state-reasons we used to manage (bug #510926). %patch12 -p1 -b .clear-old-state-reasons +# Catch DBusException in hp-systray (bug #746024). +%patch13 -p1 -b .systray-dbus-exception + # Avoid busy loop in hpcups when backend has exited (bug #525944). %patch14 -p1 -b .hpcups-sigpipe @@ -527,6 +531,9 @@ fi %postun libs -p /sbin/ldconfig %changelog +* Tue Oct 25 2011 Tim Waugh 3.11.10-7 +- Catch DBusException in hp-systray (bug #746024). + * Mon Oct 24 2011 Jiri Popelka 3.11.10-6 - Move udev rules to /lib/udev/rules.d (bug #748208).