]> git.ipfire.org Git - thirdparty/cups.git/commitdiff
Minor cleanup for PR #1.
authorMichael R Sweet <michael.r.sweet@gmail.com>
Mon, 26 Oct 2020 12:16:25 +0000 (08:16 -0400)
committerMichael R Sweet <michael.r.sweet@gmail.com>
Mon, 26 Oct 2020 12:16:25 +0000 (08:16 -0400)
cups/ppd-cache.c

index a680ca76d7b32e4ae523b110cfeb56e73f0c7f1b..aeec8c55ab61a591c864a9d9cba6c5a650d3d0d8 100644 (file)
@@ -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"))