/*++ /* NAME /* safe_ultostr 3 /* SUMMARY /* convert unsigned long to safe string /* SYNOPSIS /* #include <safe_ultostr.h> /* /* char *safe_ultostr(result, ulval, base, padlen, padchar) /* VSTRING *result; /* unsigned long ulval; /* int base; /* int padlen; /* int padchar; /* /* unsigned long safe_strtoul(start, end, base) /* const char *start; /* char **end; /* int base; /* DESCRIPTION /* The functions in this module perform conversions between /* unsigned long values and "safe" alphanumerical strings /* (strings with digits, uppercase letters and lowercase /* letters, but without the vowels AEIOUaeiou). Specifically, /* the characters B-Z represent the numbers 10-30, and b-z /* represent 31-51. /* /* safe_ultostr() converts an unsigned long value to a safe /* alphanumerical string. This is the reverse of safe_strtoul(). /* /* safe_strtoul() implements similar functionality as strtoul() /* except that it uses a safe alphanumerical string as input, /* and that it supports no signs or 0/0x prefixes. /* /* Arguments: /* .IP result /* Buffer for storage of the result of conversion to string. /* .IP ulval /* Unsigned long value. /* .IP base /* Value between 2 and 52 inclusive. /* .IP padlen /* .IP padchar /* Left-pad a short result with padchar characters to the /* specified length. Specify padlen=0 to disable padding. /* .IP start /* Pointer to the first character of the string to be converted. /* .IP end /* On return, pointer to the first character not in the input /* alphabet, or to the string terminator. /* DIAGNOSTICS /* Fatal: out of memory. /* /* safe_strtoul() returns (0, EINVAL) when no conversion could /* be performed, and (ULONG_MAX, ERANGE) in case of overflow. /* LICENSE /* .ad /* .fi /* The Secure Mailer license must be distributed with this software. /* AUTHOR(S) /* Wietse Venema /* IBM T.J. Watson Research /* P.O. Box 704 /* Yorktown Heights, NY 10598, USA
/*--*/
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.