[gnome-control-center/gnome-3-2] Printers: Set requesting-user-name when getting job info



commit c254d44f2cdecb225474b880a194942c425dc21e
Author: Marek Kasik <mkasik redhat com>
Date:   Wed Oct 26 14:18:53 2011 +0200

    Printers: Set requesting-user-name when getting job info
    
    CUPS has changed its policy for giving informations about jobs.
    This fixes problem with actualization of list of print jobs.

 panels/printers/cc-printers-panel.c |    8 +++++---
 1 files changed, 5 insertions(+), 3 deletions(-)
---
diff --git a/panels/printers/cc-printers-panel.c b/panels/printers/cc-printers-panel.c
index e729121..c416004 100644
--- a/panels/printers/cc-printers-panel.c
+++ b/panels/printers/cc-printers-panel.c
@@ -292,12 +292,14 @@ on_cups_notification (GDBusConnection *connection,
       if ((http = httpConnectEncrypt (cupsServer (), ippPort (),
                                      cupsEncryption ())) != NULL)
         {
-          request = ippNewRequest(IPP_GET_JOB_ATTRIBUTES);
-          ippAddString(request, IPP_TAG_OPERATION, IPP_TAG_URI,
+          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 ());
           ippAddStrings (request, IPP_TAG_OPERATION, IPP_TAG_KEYWORD,
                          "requested-attributes", G_N_ELEMENTS (requested_attrs), NULL, requested_attrs);
-          response = cupsDoRequest(http, request, "/");
+          response = cupsDoRequest (http, request, "/");
 
           if (response)
             {



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]