Avoid race when renaming printer (bug #975705).

Resolves: rhbz#975705
This commit is contained in:
Tim Waugh 2013-07-02 12:51:30 +01:00
parent f1346fb31a
commit 550894341b
2 changed files with 19 additions and 0 deletions

View File

@ -0,0 +1,14 @@
diff -up system-config-printer-1.4.1/system-config-printer.py.rename-race system-config-printer-1.4.1/system-config-printer.py
--- system-config-printer-1.4.1/system-config-printer.py.rename-race 2013-07-02 12:49:47.708150432 +0100
+++ system-config-printer-1.4.1/system-config-printer.py 2013-07-02 12:50:22.388173828 +0100
@@ -1278,6 +1278,10 @@ class GUI(GtkGUI):
return
(res, path, cell) = tuple
+ if path == None:
+ # Printer removed?
+ return
+
if type (cell) != Gtk.CellRendererText:
cells = self.dests_iconview.get_cells ()
for cell in cells:

View File

@ -25,6 +25,7 @@ Patch16: system-config-printer-notification-new.patch
Patch17: system-config-printer-utf8-971973.patch
Patch18: system-config-printer-statusicon-geometry.patch
Patch19: system-config-printer-remote-missing.patch
Patch20: system-config-printer-rename-race.patch
BuildRequires: cups-devel >= 1.2
BuildRequires: desktop-file-utils >= 0.2.92
@ -128,6 +129,9 @@ printers.
# Don't check for missing drivers in remote printers (bug #975058)
%patch19 -p1 -b .remote-missing
# Avoid race when renaming printer (bug #975705).
%patch20 -p1 -b .rename-race
%build
%configure --with-udev-rules
@ -228,6 +232,7 @@ exit 0
%changelog
* Tue Jul 2 2013 Tim Waugh <twaugh@redhat.com> 1.4.1-8
- Avoid race when renaming printer (bug #975705).
- Don't check for missing drivers in remote printers (bug #975058)
- Another fix from the move to gi.repository (bug #973662).
- Fixed another codec issue (bug #971973).