str_isutf8() function now returns gboolean value

Signed-off-by: Slava Zanko <slavazanko@gmail.com>
This commit is contained in:
Slava Zanko 2011-04-06 12:01:27 +03:00
parent aa2d0b07ed
commit 6cec807140
2 changed files with 4 additions and 9 deletions

View File

@ -511,10 +511,10 @@ int str_key_collate (const char *t1, const char *t2, int case_sen);
*/ */
void str_release_key (char *key, int case_sen); void str_release_key (char *key, int case_sen);
/* return 1 if codeset_name is utf8 or utf-8 /* return TRUE if codeset_name is utf8 or utf-8
* I * I
*/ */
int str_isutf8 (const char *codeset_name); gboolean str_isutf8 (const char *codeset_name);
const char *str_detect_termencoding (void); const char *str_detect_termencoding (void);

View File

@ -354,15 +354,10 @@ str_choose_str_functions (void)
} }
} }
int gboolean
str_isutf8 (const char *codeset_name) str_isutf8 (const char *codeset_name)
{ {
int result = 0; return (str_test_encoding_class (codeset_name, str_utf8_encodings) != 0);
if (str_test_encoding_class (codeset_name, str_utf8_encodings))
{
result = 1;
}
return result;
} }
void void