Rename function unicode_strlen to utf32_strlen because it really determines the length of a UTF-32 encoded string
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5900 4a71c877-e1ca-e34f-864e-861f7616d084master
parent
2cb4c71883
commit
dfa9c2bc01
|
@ -311,7 +311,7 @@ char* utf8_encode(const utf_32_char* unicode_string)
|
|||
|
||||
if (utf8_string == NULL)
|
||||
{
|
||||
debug(LOG_ERROR, "utf8_encode: Out of memory");
|
||||
debug(LOG_ERROR, "Out of memory");
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
@ -337,7 +337,7 @@ utf_32_char* utf8_decode(const char* utf8_string)
|
|||
|
||||
if (unicode_string == NULL)
|
||||
{
|
||||
debug(LOG_ERROR, "utf8_decode: Out of memory");
|
||||
debug(LOG_ERROR, "Out of memory");
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
@ -352,7 +352,7 @@ utf_32_char* utf8_decode(const char* utf8_string)
|
|||
return unicode_string;
|
||||
}
|
||||
|
||||
size_t unicode_strlen(const utf_32_char* unicode_string)
|
||||
size_t utf32_strlen(const utf_32_char* unicode_string)
|
||||
{
|
||||
size_t length = 0;
|
||||
while (*(unicode_string++))
|
||||
|
|
|
@ -60,6 +60,6 @@ utf_32_char* utf8_decode(const char* utf8_string);
|
|||
* \param unicode_string the string to determine the length of
|
||||
* \return the amount of characters found
|
||||
*/
|
||||
size_t unicode_strlen(const utf_32_char* unicode_string);
|
||||
size_t utf32_strlen(const utf_32_char* unicode_string);
|
||||
|
||||
#endif // __INCLUDE_LIB_FRAMEWORK_UTF8_H__
|
||||
|
|
Loading…
Reference in New Issue