]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
IDN: revert use of the transitional option
authorDaniel Stenberg <daniel@haxx.se>
Fri, 13 Jan 2017 13:31:40 +0000 (14:31 +0100)
committerDaniel Stenberg <daniel@haxx.se>
Fri, 13 Jan 2017 13:31:40 +0000 (14:31 +0100)
It made the german ß get converted to ss, IDNA2003 style, and we can't
have that for the .de TLD - a primary reason for our switch to IDNA2008.

Test 165 verifies.

lib/url.c

index 9112baee05a879e35e8172054d3bcabb6e4f06d2..b088b61e35baedc4451ae6afa1dd0606ff9b4c00 100644 (file)
--- a/lib/url.c
+++ b/lib/url.c
@@ -4010,12 +4010,8 @@ static void fix_hostname(struct connectdata *conn, struct hostname *host)
 #ifdef USE_LIBIDN2
     if(idn2_check_version(IDN2_VERSION)) {
       char *ace_hostname = NULL;
-#if IDN2_VERSION_NUMBER >= 0x00140000
-      int flags = IDN2_NFC_INPUT | IDN2_TRANSITIONAL;
-#else
-      int flags = IDN2_NFC_INPUT;
-#endif
-      int rc = idn2_lookup_ul((const char *)host->name, &ace_hostname, flags);
+      int rc = idn2_lookup_ul((const char *)host->name, &ace_hostname,
+                              IDN2_NFC_INPUT);
       if(rc == IDN2_OK) {
         host->encalloc = (char *)ace_hostname;
         /* change the name pointer to point to the encoded hostname */