ippAddIntegers(ipp_t      *ipp,		/* I - IPP message */
               ipp_tag_t  group,	/* I - IPP group */
	       ipp_tag_t  value_tag,	/* I - Type of attribute */
	       const char *name,	/* I - Name of attribute */
	       int        num_values,	/* I - Number of values */
	       const int  *values)	/* I - Values */
{
  int			i;		/* Looping var */
  ipp_attribute_t	*attr;		/* New attribute */
  _ipp_value_t		*value;		/* Current value */


  DEBUG_printf(("ippAddIntegers(ipp=%p, group=%02x(%s), type=%02x(%s), name=\"%s\", num_values=%d, values=%p)", (void *)ipp, group, ippTagString(group), value_tag, ippTagString(value_tag), name, num_values, (void *)values));

  value_tag &= IPP_TAG_CUPS_MASK;

 /*
  * Range check input...
  */

#if 0
  if (!ipp || !name || group < IPP_TAG_ZERO ||
      group == IPP_TAG_END || group >= IPP_TAG_UNSUPPORTED_VALUE ||
      (value_tag != IPP_TAG_INTEGER && value_tag != IPP_TAG_ENUM) ||
      num_values < 1)
    return (NULL);
#else
  if (!ipp || !name || group < IPP_TAG_ZERO ||
      group == IPP_TAG_END || group >= IPP_TAG_UNSUPPORTED_VALUE ||
      num_values < 1)
    return (NULL);
#endif /* 0 */

 /*
  * Create the attribute...
  */

  if ((attr = ipp_add_attr(ipp, name, group, value_tag, num_values)) == NULL)
    return (NULL);

  if (values)
  {
    for (i = num_values, value = attr->values;
	 i > 0;
	 i --, value ++)
      value->integer = *values++;
  }

  return (attr);
}
ippAddIntegers(ipp_t      *ipp,		 
               ipp_tag_t  group,	 
	       ipp_tag_t  value_tag,	 
	       const char *name,	 
	       int        num_values,	 
	       const int  *values)	 
{
  int			i;		 
  ipp_attribute_t	*attr;		 
  _ipp_value_t		*value;		 


  DEBUG_printf(("ippAddIntegers(ipp=%p, group=%02x(%s), type=%02x(%s), name=\"%s\", num_values=%d, values=%p)", (void *)ipp, group, ippTagString(group), value_tag, ippTagString(value_tag), name, num_values, (void *)values));

  value_tag &= IPP_TAG_CUPS_MASK;

  

#if 0
  if (!ipp || !name || group < IPP_TAG_ZERO ||
      group == IPP_TAG_END || group >= IPP_TAG_UNSUPPORTED_VALUE ||
      (value_tag != IPP_TAG_INTEGER && value_tag != IPP_TAG_ENUM) ||
      num_values < 1)
    return (NULL);
#else
  if (!ipp || !name || group < IPP_TAG_ZERO ||
      group == IPP_TAG_END || group >= IPP_TAG_UNSUPPORTED_VALUE ||
      num_values < 1)
    return (NULL);
#endif  

  

  if ((attr = ipp_add_attr(ipp, name, group, value_tag, num_values)) == NULL)
    return (NULL);

  if (values)
  {
    for (i = num_values, value = attr->values;
	 i > 0;
	 i --, value ++)
      value->integer = *values++;
  }

  return (attr);
}