From: Michael R Sweet Date: Mon, 26 Oct 2020 12:16:25 +0000 (-0400) Subject: Minor cleanup for PR #1. X-Git-Tag: v2.3.3op1~60 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5d61159fd558817e2e1c7eb6ee4c78350ddc1caa;p=thirdparty%2Fcups.git Minor cleanup for PR #1. --- diff --git a/cups/ppd-cache.c b/cups/ppd-cache.c index a680ca76d7..aeec8c55ab 100644 --- a/cups/ppd-cache.c +++ b/cups/ppd-cache.c @@ -3791,7 +3791,9 @@ _ppdCreateFromIPP(char *buffer, /* I - Filename buffer */ default_color = "RGB"; - if (ippGetCount(attr) == 1 || !ippContainsString(attr, "sgray_8") && !ippContainsString(attr, "black_1") && !ippContainsString(attr, "black_8")) + // Apparently some printers only advertise color support, so make sure + // we also do grayscale for these printers... + if (!ippContainsString(attr, "sgray_8") && !ippContainsString(attr, "black_1") && !ippContainsString(attr, "black_8")) PRINTF_COLOROPTION("Gray", _("GrayScale"), CUPS_CSPACE_SW, 8) } else if (!strcasecmp(keyword, "adobe-rgb_16") || !strcmp(keyword, "ADOBERGB48") || !strcmp(keyword, "ADOBERGB24-48"))