Re: problem with g_io_channel_read_to_end ()



> void fill_buffer(GtkTextBuffer *buffer,GIOChannel *file_desc)
>     {
>     gint *data_length;
>     GIOStatus read_status;
>     GError **error;
              ^^^^ It is wrong. I think the correct solution is: 
 GError *error = NULL;

> read_status=g_io_channel_read_to_end(file_desc,file_data,data_length,error);
And with this new error struct the function call seems like this:
read_status=g_io_channel_read_to_end(file_desc,file_data,data_length,&error);
And error handling lik this:
if (error != NULL) {
	g_error ("%s", error->message);
}

I hope this help.
Regards
Ferenc




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]