1tld_check_lz(3) libidn tld_check_lz(3)
2
3
4
6 tld_check_lz - API function
7
9 #include <tld.h>
10
11 int tld_check_lz(const char * in, size_t * errpos, const Tld_table **
12 overrides);
13
15 const char * in
16 Zero-terminated string in the current locales encoding to
17 process.
18
19 size_t * errpos
20 Position of offending character is returned here.
21
22 const Tld_table ** overrides
23 A Tld_table array of additional domain restriction struc‐
24 tures that complement and supersede the built-in informa‐
25 tion.
26
28 Test each of the characters in in for whether or not they are allowed
29 by the information in overrides or by the built-in TLD restriction
30 data. When data for the same TLD is available both internally and in
31 overrides , the information in overrides takes precedence. If several
32 entries for a specific TLD are found, the first one is used. If over‐
33 rides is NULL, only the built-in information is used. The position of
34 the first offending character is returned in errpos . Note that the
35 error position refers to the decoded character offset rather than the
36 byte position in the string.
37
38 Return value: Returns the Tld_rc value TLD_SUCCESS if all characters
39 are valid or when tld is null, TLD_INVALID if a character is not al‐
40 lowed, or additional error codes on general failure conditions.
41
43 Report bugs to <help-libidn@gnu.org>.
44 General guidelines for reporting bugs: http://www.gnu.org/gethelp/
45 GNU Libidn home page: http://www.gnu.org/software/libidn/
46
47
49 Copyright © 2002-2021 Simon Josefsson.
50 Copying and distribution of this file, with or without modification,
51 are permitted in any medium without royalty provided the copyright no‐
52 tice and this notice are preserved.
53
55 The full documentation for libidn is maintained as a Texinfo manual.
56 If the info and libidn programs are properly installed at your site,
57 the command
58
59 info libidn
60
61 should give you access to the complete manual. As an alternative you
62 may obtain the manual from:
63
64 http://www.gnu.org/software/libidn/manual/
65
66libidn 1.38 tld_check_lz(3)