Re: How to determine EOF after g_io_channel_read_to_end?



I get it. G_IO_STATUS_NORMAL just means EOF, or it will return
G_IO_STATUS_AGAIN.

Thanks :)

å 2007-05-09äç 15:06 +0800ïHu Zhengåéï
I want to implement the http client by iochannel, just send the request,
then save all the data to a buffer util the connection is closed.
Because the data may be binary, so I think it is not good to use
g_io_channel_read_line, I think g_io_channel_read_to_end should be most
suitable, but I can't determine the EOF by this function, if I don't
shutdown the iochannel by EOF information, the io watch function will
always be called with G_IO_IN.
How to determine EOF when using g_io_channel_read_to_end and doesn't use
g_io_channel_read_line?

Much thanks!

_______________________________________________
gtk-app-devel-list mailing list
gtk-app-devel-list gnome org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list




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