null returned for g_locale_to_utf8() for g_file_get_contents()
- From: Kang Jeong-Hee <Keizi mail co kr>
- To: gtk-list gnome org
- Subject: null returned for g_locale_to_utf8() for g_file_get_contents()
- Date: Sun, 7 Apr 2002 03:50:13 +0900
all that I have written is as below:
#include <glib.h>
gint main( gint argc, gchar **argv )
{
gchar *full_text;
g_file_get_contents( "ko.po", &full_text, NULL, NULL );
printf( "here: %s\n", full_text );
full_text = g_locale_to_utf8( full_text, -1, NULL, NULL, NULL );
printf( "there: %s\n", full_text );
}
ko.po is anything you want.
is this case I wanna convert euc-kr(my native) into utf8
to feed xchat 1.9 which in development against gtk2.
gtk2 require each .po as utf-8, not native anymore.
well, those cose works. you can confirm by making ko.po file with some lines of text.
but I failed with _one_ line euc-kr text.
if only one character of euc-kr is included, whole g_convert() seems to fail.
Is this a bug? or my fault to break a kinda rule?
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]