|
NetSurf
|
interface to international domain name handling. More...
Go to the source code of this file.
Macros | |
| #define | IDNA_UNICODE_CCC_VIRAMA 9 |
| Unicode canonical combining class for virama. More... | |
Functions | |
| nserror | idna_encode (const char *host, size_t len, char **ace_host, size_t *ace_len) |
| Convert a hostname to an ACE version suitable for DNS lookup. More... | |
| nserror | idna_decode (const char *ace_host, size_t ace_len, char **host, size_t *host_len) |
| Convert a hostname from ACE to UTF-8 suitable for display. More... | |
interface to international domain name handling.
Definition in file idna.h.
| #define IDNA_UNICODE_CCC_VIRAMA 9 |
| nserror idna_decode | ( | const char * | ace_host, |
| size_t | ace_len, | ||
| char ** | host, | ||
| size_t * | host_len | ||
| ) |
Convert a hostname from ACE to UTF-8 suitable for display.
| ace_host | String containing host |
| ace_len | Length of host string |
| host | Pointer to update with the output |
| host_len | Pointer to update with length of host |
If return value != NSERROR_OK, output will be left untouched.
Definition at line 785 of file idna.c.
References FQDN_APPEND, FQDN_MAX, idna__ace_to_ucs4(), idna__host_label_length(), idna__is_ace(), idna__ucs4_to_utf8(), NO_ACTION, NSERROR_BAD_URL, and NSERROR_OK.
| nserror idna_encode | ( | const char * | host, |
| size_t | len, | ||
| char ** | ace_host, | ||
| size_t * | ace_len | ||
| ) |
Convert a hostname to an ACE version suitable for DNS lookup.
| host | String containing host |
| len | Length of host string |
| ace_host | Pointer to update with the output |
| ace_len | Pointer to update with length of ace_host |
If return value != NSERROR_OK, output will be left untouched.
Definition at line 713 of file idna.c.
References FQDN_APPEND, FQDN_MAX, idna__host_label_length(), idna__is_ace(), idna__is_ldh(), idna__is_valid(), idna__ucs4_to_ace(), idna__utf8_to_ucs4(), idna__verify(), NO_ACTION, NSERROR_BAD_URL, NSERROR_OK, and NSLOG.