Re: [PATCH v2] charset: fix mm_charset_get_encoded_len

2017-08-15 Thread Aleksander Morgado
On 12/08/17 00:17, Ben Chan wrote: > The while loop in mm_charset_get_encoded_len() iterates through each > valid UTF-8 encoded character in the given NULL-terminated UTF-8 string. > It uses g_utf8_find_next_char() to find the position of the next > character. In case, g_utf8_find_next_char() retur

[PATCH v2] charset: fix mm_charset_get_encoded_len

2017-08-11 Thread Ben Chan
The while loop in mm_charset_get_encoded_len() iterates through each valid UTF-8 encoded character in the given NULL-terminated UTF-8 string. It uses g_utf8_find_next_char() to find the position of the next character. In case, g_utf8_find_next_char() returns NULL, it tries to find the end (i.e. the