rpms/cups-pk-helper/devel pk_order.patch, NONE, 1.1 cups-pk-helper.spec, 1.1, 1.2
Marek Kašík
mkasik at fedoraproject.org
Mon Jan 26 13:25:00 UTC 2009
Author: mkasik
Update of /cvs/pkgs/rpms/cups-pk-helper/devel
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv25438
Modified Files:
cups-pk-helper.spec
Added Files:
pk_order.patch
Log Message:
* Tue Jan 26 2009 Marek Kasik <mkasik at redhat.com> 0.0.3-2
- Add handling of file:/ protocol
- Change order of checked policies so the PolicyKit asks only for
"printer-enable" policy when enabling/disabling a printer
- Change order of checked policies so the PolicyKit asks only for
"printer-set-default" policy when setting default printer
pk_order.patch:
--- NEW FILE pk_order.patch ---
--- src/cups.c 2008-11-21 07:04:28.000000000 +0100
+++ src/cups.c 2009-01-23 16:28:07.000000000 +0100
@@ -1606,6 +1606,7 @@ cph_cups_is_printer_uri_local (const cha
g_str_has_prefix (lower_uri, "beh:") ||
g_str_has_prefix (lower_uri, "scsi:") ||
g_str_has_prefix (lower_uri, "serial:") ||
+ g_str_has_prefix (lower_uri, "file:") ||
g_str_has_prefix (lower_uri, "pipe:")) {
g_free (lower_uri);
return TRUE;
--- src/cups-pk-helper-mechanism.c 2008-11-21 07:28:20.000000000 +0100
+++ src/cups-pk-helper-mechanism.c 2009-01-26 13:54:44.000000000 +0100
@@ -901,21 +901,18 @@ cph_mechanism_printer_set_default (CphMe
DBusGMethodInvocation *context)
{
gboolean ret;
- const char *last_action;
+ const char *action;
reset_killtimer (mechanism);
- last_action = _cph_mechanism_get_action_for_name (mechanism, name);
+ action = _cph_mechanism_get_action_for_name (mechanism, name);
if (!_check_polkit_for_action_v (mechanism, context,
"printeraddremove",
- /* this is not the last check because
- * it's likely most useful to the user
- * to give "printer-X-edit" powers */
- "printer-default",
/* quite important, since it's
* automatically called after adding a
* printer */
- last_action,
+ action,
+ "printer-set-default",
NULL))
return FALSE;
@@ -932,21 +929,19 @@ cph_mechanism_printer_set_enabled (CphMe
DBusGMethodInvocation *context)
{
gboolean ret;
- const char *last_action;
+ const char *action;
reset_killtimer (mechanism);
- last_action = _cph_mechanism_get_action_for_name (mechanism, name);
+ action = _cph_mechanism_get_action_for_name (mechanism, name);
+
if (!_check_polkit_for_action_v (mechanism, context,
"printeraddremove",
- /* this is not the last check because
- * it's likely most useful to the user
- * to give "printer-X-edit" powers */
- "printer-enable",
/* quite important, since it's
* automatically called after adding a
* printer */
- last_action,
+ action,
+ "printer-enable",
NULL))
return FALSE;
Index: cups-pk-helper.spec
===================================================================
RCS file: /cvs/pkgs/rpms/cups-pk-helper/devel/cups-pk-helper.spec,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- cups-pk-helper.spec 20 Jan 2009 12:30:21 -0000 1.1
+++ cups-pk-helper.spec 26 Jan 2009 13:24:30 -0000 1.2
@@ -1,6 +1,6 @@
Name: cups-pk-helper
Version: 0.0.3
-Release: 1%{?dist}
+Release: 2%{?dist}
Summary: A helper that makes system-config-printer use PolicyKit
Group: System Environment/Base
@@ -9,6 +9,7 @@
Source0: http://www.vuntz.net/download/cups-pk-helper/cups-pk-helper-%{version}.tar.bz2
Patch0: dependencies.patch
+Patch1: pk_order.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
@@ -32,6 +33,7 @@
%setup -q
%patch0 -p0 -b .dependencies
+%patch1 -p0 -b .pk-order
%build
%configure
@@ -58,6 +60,12 @@
%changelog
+* Tue Jan 26 2009 Marek Kasik <mkasik at redhat.com> 0.0.3-2
+- Add handling of file:/ protocol
+- Change order of checked policies so the PolicyKit asks only for
+ "printer-enable" policy when enabling/disabling a printer
+- Change order of checked policies so the PolicyKit asks only for
+ "printer-set-default" policy when setting default printer
* Tue Jan 13 2009 Marek Kasik <mkasik at redhat.com> 0.0.3-1
- Initial spec file.
More information about the fedora-extras-commits
mailing list