[gnome-settings-daemon] print-notifications: Set requesting-user-name when getting job info
- From: Marek KaÅÃk <mkasik src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-settings-daemon] print-notifications: Set requesting-user-name when getting job info
- Date: Wed, 26 Oct 2011 11:25:38 +0000 (UTC)
commit d0acb5cb98ebabb88c2c40c3d0bcfc872d4b32d0
Author: Marek Kasik <mkasik redhat com>
Date: Wed Oct 26 13:25:15 2011 +0200
print-notifications: Set requesting-user-name when getting job info
CUPS has changed its policy for giving informations about jobs.
This fixes problem with getting of information about ownership
of print jobs.
.../gsd-print-notifications-manager.c | 11 +++++++----
1 files changed, 7 insertions(+), 4 deletions(-)
---
diff --git a/plugins/print-notifications/gsd-print-notifications-manager.c b/plugins/print-notifications/gsd-print-notifications-manager.c
index 0c36edb..bffb695 100644
--- a/plugins/print-notifications/gsd-print-notifications-manager.c
+++ b/plugins/print-notifications/gsd-print-notifications-manager.c
@@ -323,11 +323,14 @@ on_cups_notification (GDBusConnection *connection,
else {
job_uri = g_strdup_printf ("ipp://localhost/jobs/%d", job_id);
- request = ippNewRequest(IPP_GET_JOB_ATTRIBUTES);
- ippAddString(request, IPP_TAG_OPERATION, IPP_TAG_URI, "job-uri", NULL, job_uri);
- ippAddString(request, IPP_TAG_OPERATION, IPP_TAG_KEYWORD,
+ request = ippNewRequest (IPP_GET_JOB_ATTRIBUTES);
+ ippAddString (request, IPP_TAG_OPERATION, IPP_TAG_URI,
+ "job-uri", NULL, job_uri);
+ ippAddString (request, IPP_TAG_OPERATION, IPP_TAG_NAME,
+ "requesting-user-name", NULL, cupsUser ());
+ ippAddString (request, IPP_TAG_OPERATION, IPP_TAG_KEYWORD,
"requested-attributes", NULL, "job-originating-user-name");
- response = cupsDoRequest(http, request, "/");
+ response = cupsDoRequest (http, request, "/");
if (response) {
if (response->request.status.status_code <= IPP_OK_CONFLICT &&
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]