rpms/system-config-printer/F-11 system-config-printer-copy-crash.patch, NONE, 1.1 system-config-printer.spec, 1.329, 1.330

Tim Waugh twaugh at fedoraproject.org
Mon Jan 11 15:59:41 UTC 2010


Author: twaugh

Update of /cvs/pkgs/rpms/system-config-printer/F-11
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv4353

Modified Files:
	system-config-printer.spec 
Added Files:
	system-config-printer-copy-crash.patch 
Log Message:
* Mon Jan 11 2010 Tim Waugh <twaugh at redhat.com> - 1.1.16-7
- Fixed traceback when copying printer with certain job options
  set (bug #554268).


system-config-printer-copy-crash.patch:
 options.py               |   13 ++++++++++---
 system-config-printer.py |    5 +++--
 2 files changed, 13 insertions(+), 5 deletions(-)

--- NEW FILE system-config-printer-copy-crash.patch ---
diff -up system-config-printer-1.1.16/options.py.copy-crash system-config-printer-1.1.16/options.py
--- system-config-printer-1.1.16/options.py.copy-crash	2009-12-22 14:44:19.000000000 +0000
+++ system-config-printer-1.1.16/options.py	2010-01-11 15:52:50.581036024 +0000
@@ -1,8 +1,9 @@
 ## system-config-printer
 
-## Copyright (C) 2006, 2007, 2008 Red Hat, Inc.
-## Copyright (C) 2008 Tim Waugh <twaugh at redhat.com>
-## Copyright (C) 2006 Florian Festi <ffesti at redhat.com>
+## Copyright (C) 2006, 2007, 2008, 2010 Red Hat, Inc.
+## Authors:
+##  Tim Waugh <twaugh at redhat.com>
+##  Florian Festi <ffesti at redhat.com>
 
 ## This program is free software; you can redistribute it and/or modify
 ## it under the terms of the GNU General Public License as published by
@@ -63,6 +64,9 @@ def OptionWidget(name, v, s, on_change):
 # ---------------------------------------------------------------------------
 
 class OptionInterface:
+    def get_default(self):
+        return None
+
     def get_current_value(self):
         raise NotImplemented
 
@@ -105,6 +109,9 @@ class OptionAlwaysShown(OptionInterface)
         self.use_supported = use_supported
         self.reinit (None)
 
+    def get_default(self):
+        return self.system_default
+
     def set_default(self, system_default):
         # For the media option, the system default depends on the printer's
         # PageSize setting.  This method allows the main module to tell us
diff -up system-config-printer-1.1.16/system-config-printer.py.copy-crash system-config-printer-1.1.16/system-config-printer.py
--- system-config-printer-1.1.16/system-config-printer.py.copy-crash	2010-01-11 15:52:42.178911479 +0000
+++ system-config-printer-1.1.16/system-config-printer.py	2010-01-11 15:52:50.589911263 +0000
@@ -2068,9 +2068,10 @@ class GUI(GtkGUI, monitor.Watcher):
                 if option not in self.server_side_options:
                     printer.unsetOption(option)
             for option in self.server_side_options.itervalues():
+                print option.name, option.is_changed(), saveall
                 if (option.is_changed() or
-                    saveall and
-                    option.get_current_value () != option.system_default):
+                    (saveall and
+                     option.get_current_value () != option.get_default())):
                     printer.setOption(option.name, option.get_current_value())
 
         except cups.IPPError, (e, s):


Index: system-config-printer.spec
===================================================================
RCS file: /cvs/pkgs/rpms/system-config-printer/F-11/system-config-printer.spec,v
retrieving revision 1.329
retrieving revision 1.330
diff -u -p -r1.329 -r1.330
--- system-config-printer.spec	11 Jan 2010 15:41:28 -0000	1.329
+++ system-config-printer.spec	11 Jan 2010 15:59:41 -0000	1.330
@@ -7,7 +7,7 @@
 Summary: A printer administration tool
 Name: system-config-printer
 Version: 1.1.16
-Release: 6%{?dist}
+Release: 7%{?dist}
 License: GPLv2+
 URL: http://cyberelk.net/tim/software/system-config-printer/
 Group: System Environment/Base
@@ -24,6 +24,7 @@ Patch6: system-config-printer-notificati
 Patch7: system-config-printer-select-nonexistent-printer.patch
 Patch8: system-config-printer-ink-levels.patch
 Patch9: system-config-printer-auth-no-pw.patch
+Patch10: system-config-printer-copy-crash.patch
 
 Patch101: pycups-request-readio.patch
 
@@ -83,6 +84,7 @@ the configuration tool.
 %patch7 -p1 -b .select-nonexistent-printer
 %patch8 -p1 -b .ink-levels
 %patch9 -p1 -b .auth-no-pw
+%patch10 -p1 -b .copy-crash
 
 pushd pycups-%{pycups_version}
 %patch101 -p1 -b .request-readio
@@ -193,6 +195,10 @@ rm -rf %buildroot
 exit 0
 
 %changelog
+* Mon Jan 11 2010 Tim Waugh <twaugh at redhat.com> - 1.1.16-7
+- Fixed traceback when copying printer with certain job options
+  set (bug #554268).
+
 * Mon Jan 11 2010 Tim Waugh <twaugh at redhat.com> - 1.1.16-6
 - Fixed traceback introduced in recent fix (bug #554376).
 



More information about the scm-commits mailing list