wok-next view gnutls/stuff/patches/gnutls-3.5.19-idn2.patch @ rev 21457
updated sshfs-fuse (3.3.1 -> 3.7.0)
author | Hans-G?nter Theisgen |
---|---|
date | Thu May 07 14:36:33 2020 +0100 (2020-05-07) |
parents | |
children |
line source
1 From b0dfccd2149086cf5d2db44c329664a56b126216 Mon Sep 17 00:00:00 2001
2 From: Alon Bar-Lev <alon.barlev@gmail.com>
3 Date: Sun, 6 Jan 2019 20:02:50 +0200
4 Subject: [PATCH] idn2: do not use deprecated idn2_to_unicode_8z8z in
5 idn2-2.1.0
7 Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
8 ---
9 lib/str-idna.c | 6 +++---
10 1 file changed, 3 insertions(+), 3 deletions(-)
12 https://gitlab.com/gnutls/gnutls/merge_requests/864
14 diff --git a/lib/str-idna.c b/lib/str-idna.c
15 index 3bf2db877..95ca9b769 100644
16 --- a/lib/str-idna.c
17 +++ b/lib/str-idna.c
18 @@ -145,7 +145,7 @@ int gnutls_idna_map(const char *input, unsigned ilen, gnutls_datum_t *out, unsig
19 return ret;
20 }
22 -#ifdef HAVE_LIBIDN2
23 +#if defined(HAVE_LIBIDN2) && IDN2_VERSION_NUMBER < 0x02000000
24 int _idn2_punycode_decode(
25 size_t input_length,
26 const char input[],
27 @@ -153,7 +153,7 @@ int _idn2_punycode_decode(
28 uint32_t output[],
29 unsigned char case_flags[]);
31 -static int _idn2_to_unicode_8z8z(const char *src, char **dst)
32 +static int idn2_to_unicode_8z8z(const char *src, char **dst, int flags)
33 {
34 int rc, run;
35 size_t out_len = 0;
36 @@ -253,7 +253,7 @@ int gnutls_idna_reverse_map(const char *input, unsigned ilen, gnutls_datum_t *ou
38 #ifdef HAVE_LIBIDN2
39 /* currently libidn2 just converts single labels, thus a wrapper function */
40 - rc = _idn2_to_unicode_8z8z((char*)istr.data, &u8);
41 + rc = idn2_to_unicode_8z8z((char*)istr.data, &u8, 0);
42 if (rc != IDN2_OK) {
43 gnutls_assert();
44 _gnutls_debug_log("unable to convert ACE name '%s' to UTF-8 format: %s\n", istr.data, idn2_strerror(rc));
45 --
46 2.19.2