polling sockets using glib



Hi,
I am writing a server application (using glib) in which I want to be able to (frequently) turn polling on and off for given sockets.

I am currently using g_io_add_watch to add a watch on a socket and g_source_remove to remove the watch. This seems like an expensive way of doing what I want. What is the recommended way of doing this?

Peter Robinson





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