ippSetDate(ipp_t             *ipp,	/* I  - IPP message */
           ipp_attribute_t   **attr,	/* IO - IPP attribute */
           int               element,	/* I  - Value number (0-based) */
           const ipp_uchar_t *datevalue)/* I  - dateTime value */
{
  _ipp_value_t	*value;			/* Current value */


 /*
  * Range check input...
  */

  if (!ipp || !attr || !*attr || ((*attr)->value_tag != IPP_TAG_DATE && (*attr)->value_tag != IPP_TAG_NOVALUE && (*attr)->value_tag != IPP_TAG_UNKNOWN) || element < 0 || element > (*attr)->num_values || !datevalue)
    return (0);

 /*
  * Set the value and return...
  */

  if ((value = ipp_set_value(ipp, attr, element)) != NULL)
    memcpy(value->date, datevalue, sizeof(value->date));

  return (value != NULL);
}
ippSetDate(ipp_t             *ipp,	 
           ipp_attribute_t   **attr,	 
           int               element,	 
           const ipp_uchar_t *datevalue) 
{
  _ipp_value_t	*value;			 


  

  if (!ipp || !attr || !*attr || ((*attr)->value_tag != IPP_TAG_DATE && (*attr)->value_tag != IPP_TAG_NOVALUE && (*attr)->value_tag != IPP_TAG_UNKNOWN) || element < 0 || element > (*attr)->num_values || !datevalue)
    return (0);

  

  if ((value = ipp_set_value(ipp, attr, element)) != NULL)
    memcpy(value->date, datevalue, sizeof(value->date));

  return (value != NULL);
}