]> git.ipfire.org Git - thirdparty/cups.git/commitdiff
Fix ippEnumString for standard operations.
authormike <mike@7a7537e8-13f0-0310-91df-b6672ffda945>
Thu, 31 Jan 2013 13:02:33 +0000 (13:02 +0000)
committermike <mike@7a7537e8-13f0-0310-91df-b6672ffda945>
Thu, 31 Jan 2013 13:02:33 +0000 (13:02 +0000)
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/trunk@10844 7a7537e8-13f0-0310-91df-b6672ffda945

cups/ipp-support.c

index 6b7dcbb8e7c437ed40eeb40f0f4b024f935f893a..3b4d66ed210ddd2587509be45a568466cfe94c12 100644 (file)
@@ -151,8 +151,8 @@ static const char * const ipp_status_oks[] =        /* "OK" status codes */
 static const char * const ipp_std_ops[] =
                {
                  /* 0x0000 - 0x000f */
-                 "0x00",
-                 "0x01",
+                 "0x0000",
+                 "0x0001",
                  "Print-Job",
                  "Print-URI",
                  "Validate-Job",
@@ -166,7 +166,7 @@ static const char * const ipp_std_ops[] =
                  "Hold-Job",
                  "Release-Job",
                  "Restart-Job",
-                 "0x0f",
+                 "0x000f",
 
                  /* 0x0010 - 0x001f */
                  "Pause-Printer",
@@ -207,7 +207,7 @@ static const char * const ipp_std_ops[] =
                  /* 0x0030 - 0x003d */
                  "Promote-Job",
                  "Schedule-Job-After",
-                 "0x32",
+                 "0x0032",
                  "Cancel-Document",
                  "Get-Document-Attributes",
                  "Get-Documents",
@@ -1698,7 +1698,8 @@ ippEnumString(const char *attrname,       /* I - Attribute name */
   else if (!strcmp(attrname, "job-state") &&
           enumvalue >= IPP_JOB_PENDING && enumvalue <= IPP_JOB_COMPLETED)
     return (ipp_job_states[enumvalue - IPP_JOB_PENDING]);
-  else if (!strcmp(attrname, "operations-supported"))
+  else if (!strcmp(attrname, "operations-supported") ||
+           !strcmp(attrname, "limit-operations-supported"))
     return (ippOpString((ipp_op_t)enumvalue));
   else if ((!strcmp(attrname, "orientation-requested") ||
             !strcmp(attrname, "orientation-requested-actual") ||
@@ -1923,7 +1924,7 @@ ippOpString(ipp_op_t op)          /* I - Operation ID */
   * See if the operation ID is a known value...
   */
 
-  if (op >= IPP_OP_PRINT_JOB && op <= IPP_OP_CLOSE_JOB)
+  if (op >= IPP_OP_PRINT_JOB && op <= IPP_OP_VALIDATE_DOCUMENT)
     return (ipp_std_ops[op]);
   else if (op == IPP_OP_PRIVATE)
     return ("windows-ext");