imap/src/mailutil/mailutil.c
/* Parse a number
 * Accepts: pointer to integer to return
 *	    pointer to strtok state
 * Returns: T if successful, else NIL
 */
Parse a number
Accepts: pointer to integer to return
pointer to strtok state
Returns: T if successful, else NIL
Parse a number Accepts : pointer to integer to return pointer to strtok state Returns : T if successful else NIL
int criteria_number (unsigned long *number,char **r)
{
  char *t;
  STRINGLIST *s = NIL;
  int ret = (mail_criteria_string (&s,r) &&
	     (*number = strtoul ((char *) s->text.data,&t,10)) && !*t) ?
	       T : NIL;
  if (s) mail_free_stringlist (&s);
  return ret;
}
int criteria_number ( unsigned long * number , char * * r ) { char * t ; STRINGLIST * s = NIL ; int ret = ( mail_criteria_string ( & s , r ) && ( * number = strtoul ( ( char * ) s -> text . data , & t , 10 ) ) && ! * t ) ? T : NIL ; if ( s ) mail_free_stringlist ( & s ) ; return ret ; }
Parse a number
 Accepts: pointer to integer to return
          pointer to strtok state
 Returns: T if successful, else NIL
Parse a number Accepts : pointer to integer to return pointer to strtok state Returns : T if successful else NIL
/* parse the date and return fn if OK */