-----------------------
- Updated the systemd service file for cupsd (Issue #5551)
+- The `cupsCheckDestSupported` function did not check octetString values
+ correctly (Issue #5557)
- The scheduler did not encode octetString values like "job-password" correctly
for the print filters (Issue #5558)
/*
* Destination option/media support for CUPS.
*
- * Copyright 2012-2017 by Apple Inc.
+ * Copyright 2012-2019 by Apple Inc.
*
* These coded instructions, statements, and computer programs are the
* property of Apple Inc. and are protected by Federal copyright
ipp_res_t units_value; /* Resolution units */
ipp_attribute_t *attr; /* Attribute */
_ipp_value_t *attrval; /* Current attribute value */
+ _ipp_option_t *map; /* Option mapping information */
/*
* Check literal values...
*/
+ map = _ippFindOption(option);
+
switch (attr->value_tag)
{
case IPP_TAG_INTEGER :
+ if (map && map->value_tag == IPP_TAG_STRING)
+ return (strlen(value) <= (size_t)attr->values[0].integer);
+
case IPP_TAG_ENUM :
int_value = atoi(value);
return (attr->values[0].boolean);
case IPP_TAG_RANGE :
- int_value = atoi(value);
+ if (map && map->value_tag == IPP_TAG_STRING)
+ int_value = (int)strlen(value);
+ else
+ int_value = atoi(value);
for (i = 0; i < attr->num_values; i ++)
if (int_value >= attr->values[i].range.lower &&