X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=lib%2Funicode.h;h=b2078e6dce0ad33a6535c2f14d56099c1628bbfe;hb=05e547e7ee479fa2c3ca5bc9d2eb57bc8a07bdb8;hp=0f20bdc78ee9ee326d154941b35af1ac2fb5b9ce;hpb=f38b84ea2b6b61d309c604faedd41ab3b0fcf16b;p=sliver-openvswitch.git diff --git a/lib/unicode.h b/lib/unicode.h index 0f20bdc78..b2078e6dc 100644 --- a/lib/unicode.h +++ b/lib/unicode.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2009 Nicira Networks. + * Copyright (c) 2009, 2010 Nicira Networks. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -18,6 +18,8 @@ #define UNICODE_H 1 #include +#include +#include "compiler.h" /* Returns true if 'c' is a Unicode code point, otherwise false. */ static inline bool @@ -50,4 +52,7 @@ uc_is_surrogate(int c) int utf16_decode_surrogate_pair(int leading, int trailing); +size_t utf8_length(const char *); +char *utf8_validate(const char *, size_t *lengthp) WARN_UNUSED_RESULT; + #endif /* unicode.h */