summaryrefslogtreecommitdiffstats
path: root/mutt_idna.c
diff options
context:
space:
mode:
authorThomas Roessler <roessler@does-not-exist.org>2009-03-28 22:37:22 +0100
committerThomas Roessler <roessler@does-not-exist.org>2009-03-28 22:37:22 +0100
commite2494538aa50da3dd2bea68e60e6f911d92327f0 (patch)
treec07382eb074f39c34e87a206413cdeb1560dac11 /mutt_idna.c
parentb2803e765df5ca8bacab3448429f2f61a4bb5258 (diff)
Make IDNA code more readable
Diffstat (limited to 'mutt_idna.c')
-rw-r--r--mutt_idna.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/mutt_idna.c b/mutt_idna.c
index 40b207a2..f720116a 100644
--- a/mutt_idna.c
+++ b/mutt_idna.c
@@ -62,7 +62,7 @@ static int mutt_idna_to_local (const char *in, char **out, int flags)
goto notrans;
/* Is this the right function? Interesting effects with some bad identifiers! */
- if (idna_to_unicode_8z8z (in, out, 1) != IDNA_SUCCESS)
+ if (idna_to_unicode_8z8z (in, out, IDNA_ALLOW_UNASSIGNED) != IDNA_SUCCESS)
goto notrans;
/* we don't want charset-hook effects, so we set flags to 0 */
@@ -83,7 +83,7 @@ static int mutt_idna_to_local (const char *in, char **out, int flags)
/* we don't want charset-hook effects, so we set flags to 0 */
if (mutt_convert_string (&tmp, Charset, "utf-8", 0) == -1)
irrev = 1;
- if (!irrev && idna_to_ascii_8z (tmp, &t2, 1) != IDNA_SUCCESS)
+ if (!irrev && idna_to_ascii_8z (tmp, &t2, IDNA_ALLOW_UNASSIGNED) != IDNA_SUCCESS)
irrev = 1;
if (!irrev && ascii_strcasecmp (t2, in))
{
@@ -122,7 +122,7 @@ static int mutt_local_to_idna (const char *in, char **out)
/* we don't want charset-hook effects, so we set flags to 0 */
if (mutt_convert_string (&tmp, Charset, "utf-8", 0) == -1)
rv = -1;
- if (!rv && idna_to_ascii_8z (tmp, out, 1) != IDNA_SUCCESS)
+ if (!rv && idna_to_ascii_8z (tmp, out, IDNA_ALLOW_UNASSIGNED) != IDNA_SUCCESS)
rv = -2;
FREE (&tmp);