This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Preview patch for libidn2-based IDNA implementation


On 01/10/2018 06:49 PM, Dmitry V. Levin wrote:

+/* IDNA conversion.  These functions convert domain names between the
+   current multi-byte character set and the IDNA encoding.  On
+   success, the result string is written to *RESULT (which the caller
+   has to free), and zero is returned.  On error, an EAI_* error code
+   is returned (see <netdb.h>), and *RESULT is not changed.  */
+int __idna_to_dns_encoding (const char *name, char **result);
+libc_hidden_proto (__idna_to_dns_encoding)
+int __idna_from_dns_encoding (const char *name, char **);

Shouldn't it be "char **result", too?

--- a/resolv/netdb.h
+++ b/resolv/netdb.h
@@ -605,10 +605,10 @@ struct gaicb
  				   in the current locale's character set)
  				   before looking it up. */
  #  define AI_CANONIDN	0x0080	/* Translate canonical name from IDN format. */
-#  define AI_IDN_ALLOW_UNASSIGNED 0x0100 /* Don't reject unassigned Unicode
-					    code points.  */
-#  define AI_IDN_USE_STD3_ASCII_RULES 0x0200 /* Validate strings according to
-						STD3 rules.  */
+#  define AI_IDN_ALLOW_UNASSIGNED \
+  __glibc_macro_warning ("AI_IDN_ALLOW_UNASSIGNED") 0x0100
+#  define AI_IDN_USE_STD3_ASCII_RULES \
+  __glibc_macro_warning ("AI_IDN_USE_STD3_ASCII_RULES") 0x0200

The accepted style for these warnings is "... is deprecated".

Thanks, both fixed locally.

Florian


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]