Re: [gnet-dev] Re: [gimpwin-dev] Windows sockets
- From: Tor Lillqvist <tml iki fi>
- To: gimpwin-dev yahoogroups com
- Cc: jpe wingide com, gnet-dev gnetlibrary org
- Subject: Re: [gnet-dev] Re: [gimpwin-dev] Windows sockets
- Date: Thu, 7 Mar 2002 23:47:29 +0200 (FLE Standard Time)
> > It looks like the main loop uses f->fd as the handle to wait on (line 216
> > of gmain.c). Shouldn't this be waiting on the data_avail_event?
Hmm. You are looking at some rather old gmain.c then, if line 216 has
something related to that.
But anyway, on Windows, the fd field in a GPollFD, is not a "file
descriptor" as on Unix, but a Windows HANDLE that can be used in the
WaitForMultipleObjects() function. In
giowin32.c:g_io_win32_create_watch():
watch->pollfd.fd = (gint) win32_channel->data_avail_event;
So it indeed is the data_avail_event that the code in gmain.c will
eventuall be waiting on.
--tml
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]