From 939368f09e2997a68edb43fab008fd61061ba2b9 Mon Sep 17 00:00:00 2001 From: Michael R Sweet Date: Fri, 5 Apr 2024 16:44:33 -0400 Subject: [PATCH] Fix document-unprintable-error support (Issue #391) --- CHANGES.md | 1 + backend/ipp.c | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/CHANGES.md b/CHANGES.md index e69ee8ac18..a4222f6df5 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -13,6 +13,7 @@ Changes in CUPS v2.4.8 (TBA) - Raised `cups_enum_dests()` timeout for listing available IPP printers (Issue #751) - Fixed mapping of PPD InputSlot, MediaType, and OutputBin values (Issue #238) +- Fixed "document-unprintable-error" handling (Issue #391) - Fixed the web interface not showing an error for a non-existent printer (Issue #423) - Fixed printing of jobs with job name longer than 255 chars on older printers diff --git a/backend/ipp.c b/backend/ipp.c index 2bbdefbd1f..8609e3a283 100644 --- a/backend/ipp.c +++ b/backend/ipp.c @@ -1919,7 +1919,7 @@ main(int argc, /* I - Number of command-line args */ if (ippContainsString(reasons, "document-format-error")) ipp_status = IPP_STATUS_ERROR_DOCUMENT_FORMAT_ERROR; - else if (ippContainsString(reasons, "document-unprintable")) + else if (ippContainsString(reasons, "document-unprintable-error")) ipp_status = IPP_STATUS_ERROR_DOCUMENT_UNPRINTABLE; ippDelete(response); @@ -2708,7 +2708,7 @@ monitor_printer( new_reasons |= _CUPS_JSR_JOB_RELEASE_WAIT; else if (!strcmp(attr->values[i].string.text, "document-format-error")) new_reasons |= _CUPS_JSR_DOCUMENT_FORMAT_ERROR; - else if (!strcmp(attr->values[i].string.text, "document-unprintable")) + else if (!strcmp(attr->values[i].string.text, "document-unprintable-error")) new_reasons |= _CUPS_JSR_DOCUMENT_UNPRINTABLE; if (!job_canceled && (!strncmp(attr->values[i].string.text, "job-canceled-", 13) || !strcmp(attr->values[i].string.text, "aborted-by-system"))) -- 2.47.2