Hello guys: As I using the GLIB IO Channels, I meet some problem. I wanna use the IO Channels write a large memory into the file. Follows is my code segment... ... FILE* mem_dump = fopen("MEM_DUMP.txt","w"); guint bytes = 0 , tmp = 0; ... elf_pt = g_malloc0(59397); GIOChannel* gioc = g_io_channel_unix_new((int)mem_dump); g_io_channel_init(gioc); g_io_channel_write(gioc,elf_pt,59397, &tmp); ... g_io_channel_close(gioc); fclose(mem_dump); when execution, I got the follows message... (process:12649): GLib-WARNING **: giounix.c:400Error while getting flags for FD: Bad file descriptor (9) (process:12649): GLib-WARNING **: Invalid file descriptor. I have no idea to solve this problem. any good idea???? Thanx!!! PS: I'm using the UNIX system.
_______________________________________________ gtk-list@xxxxxxxxx http://mail.gnome.org/mailman/listinfo/gtk-list