diff options
author | Paul Aurich <darkrain42@pidgin.im> | 2009-07-19 23:45:13 +0000 |
---|---|---|
committer | Paul Aurich <darkrain42@pidgin.im> | 2009-07-19 23:45:13 +0000 |
commit | fcc4a7c373963804afaaa75f0a4d519a17805e4f (patch) | |
tree | 555c97c81bb8e4b8007c67f359d16a77be1e45b6 /libpurple/protocols/jabber/jutil.c | |
parent | 82c2439555dd518ff61de15133db2b413f0540dd (diff) | |
download | pidgin-fcc4a7c373963804afaaa75f0a4d519a17805e4f.tar.gz |
Move the IDN support into the DNS routines.
This turned out to be cleaner than I first thought, so here we go.
All libpurple DNS routines support IDN when built against GNU libidn.
Diffstat (limited to 'libpurple/protocols/jabber/jutil.c')
-rw-r--r-- | libpurple/protocols/jabber/jutil.c | 22 |
1 files changed, 0 insertions, 22 deletions
diff --git a/libpurple/protocols/jabber/jutil.c b/libpurple/protocols/jabber/jutil.c index 5c8bedd3ed..85791fd64a 100644 --- a/libpurple/protocols/jabber/jutil.c +++ b/libpurple/protocols/jabber/jutil.c @@ -37,28 +37,6 @@ static char idn_buffer[1024]; #endif -gchar *jabber_try_idna_to_ascii(const char *input) -{ -#ifndef USE_IDN - return g_strdup(input); -#else - gchar *out; - char *tmp; - - g_return_val_if_fail(input != NULL, NULL); - g_return_val_if_fail(*input != '\0', NULL); - - if (idna_to_ascii_8z(input, &tmp, IDNA_USE_STD3_ASCII_RULES) != IDNA_SUCCESS) { - return NULL; - } - - out = g_strdup(tmp); - /* This *MUST* be freed with free, not g_free */ - free(tmp); - return out; -#endif -} - #ifdef USE_IDN static gboolean jabber_nodeprep(char *str, size_t buflen) { |