aboutsummaryrefslogtreecommitdiffstats
path: root/util-src
diff options
context:
space:
mode:
authorTobias Markmann <tm@ayena.de>2010-12-14 18:54:55 +0100
committerTobias Markmann <tm@ayena.de>2010-12-14 18:54:55 +0100
commitc1efda1ffd82e6988ab20b4be5f75ecf31fb551e (patch)
treeabe5de7670bee8ca9717c1c5f21f45aa18554b0b /util-src
parent798aeefcfbd2db78ca949b2c47f0b37ce4d8ea6c (diff)
downloadprosody-c1efda1ffd82e6988ab20b4be5f75ecf31fb551e.tar.gz
prosody-c1efda1ffd82e6988ab20b4be5f75ecf31fb551e.zip
Make libidn default when not specifiying a IDN lib.
Diffstat (limited to 'util-src')
-rw-r--r--util-src/encodings.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/util-src/encodings.cpp b/util-src/encodings.cpp
index da2d10bb..81230afe 100644
--- a/util-src/encodings.cpp
+++ b/util-src/encodings.cpp
@@ -122,8 +122,9 @@ static const luaL_Reg Reg_base64[] =
/***************** STRINGPREP *****************/
#ifndef USE_STRINGPREP_ICU
/****************** libidn ********************/
+extern "C" {
#include <stringprep.h>
-
+}
static int stringprep_prep(lua_State *L, const Stringprep_profile *profile)
{
size_t len;
@@ -140,7 +141,7 @@ static int stringprep_prep(lua_State *L, const Stringprep_profile *profile)
return 1; // TODO return error message
}
strcpy(string, s);
- ret = stringprep(string, 1024, 0, profile);
+ ret = stringprep(string, 1024, (Stringprep_profile_flags)0, profile);
if (ret == STRINGPREP_OK) {
lua_pushstring(L, string);
return 1;
@@ -169,7 +170,6 @@ static const luaL_Reg Reg_stringprep[] =
#else
#include <unicode/usprep.h>
-//#include <unicode/stringpiece.h>
#include <unicode/unistr.h>
#include <unicode/utrace.h>