Skip to content

Commit

Permalink
Update cupsCreateRequestedArray for Get-Output-Device-Attributes.
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelrsweet committed Feb 16, 2024
1 parent 4b92af3 commit ce33984
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
3 changes: 2 additions & 1 deletion CHANGES.md
Expand Up @@ -14,7 +14,8 @@ libcups v3.0rc1 (TBD)
- Updated `httpAddrConnect()` to handle `POLLHUP` together with `POLLIN` or
`POLLOUT`.
- Updated the various tool man pages, usage output, and examples.
- Updated `ippCreateRequestedArray` for the Get-Documents operation.
- Updated `ippCreateRequestedArray` for the Get-Documents and
Get-Output-Device-Attributes operations.
- Now use installed PDFio library, if available.
- Now use NotoSansMono font for `ipptransform` text conversions.
- The `ipptransform` program now supports uncollated copies.
Expand Down
6 changes: 3 additions & 3 deletions cups/ipp-support.c
@@ -1,7 +1,7 @@
//
// Internet Printing Protocol support functions for CUPS.
//
// Copyright © 2022-2023 by OpenPrinting.
// Copyright © 2022-2024 by OpenPrinting.
// Copyright © 2007-2018 by Apple Inc.
// Copyright © 1997-2007 by Easy Software Products, all rights reserved.
//
Expand Down Expand Up @@ -2055,15 +2055,15 @@ ippCreateRequestedArray(ipp_t *request) // I - IPP request
added = true;
}

if (!strcmp(value, "job-template") || (!strcmp(value, "all") && (op == IPP_OP_GET_JOB_ATTRIBUTES || op == IPP_OP_GET_JOBS || op == IPP_OP_GET_PRINTER_ATTRIBUTES)))
if (!strcmp(value, "job-template") || (!strcmp(value, "all") && (op == IPP_OP_GET_JOB_ATTRIBUTES || op == IPP_OP_GET_JOBS || op == IPP_OP_GET_PRINTER_ATTRIBUTES || op == IPP_OP_GET_OUTPUT_DEVICE_ATTRIBUTES)))
{
for (j = 0; j < (sizeof(job_template) / sizeof(job_template[0])); j ++)
cupsArrayAdd(ra, (void *)job_template[j]);

added = true;
}

if (!strcmp(value, "printer-description") || (!strcmp(value, "all") && (op == IPP_OP_GET_PRINTER_ATTRIBUTES || op == IPP_OP_GET_PRINTERS || op == IPP_OP_CUPS_GET_DEFAULT || op == IPP_OP_CUPS_GET_PRINTERS || op == IPP_OP_CUPS_GET_CLASSES)))
if (!strcmp(value, "printer-description") || (!strcmp(value, "all") && (op == IPP_OP_GET_PRINTER_ATTRIBUTES || op == IPP_OP_GET_OUTPUT_DEVICE_ATTRIBUTES || op == IPP_OP_GET_PRINTERS || op == IPP_OP_CUPS_GET_DEFAULT || op == IPP_OP_CUPS_GET_PRINTERS || op == IPP_OP_CUPS_GET_CLASSES)))
{
for (j = 0; j < (sizeof(printer_description) / sizeof(printer_description[0])); j ++)
cupsArrayAdd(ra, (void *)printer_description[j]);
Expand Down

0 comments on commit ce33984

Please sign in to comment.