2

I use blocking IO (because this seems the easiest way to write larger amounts of data to a socket).

I would like to detect if there is any data to read, so I use g_io_channel_get_buffer_condition(). The problem is that it will always give back 4, and the bit 1 for G_IO_IN is never set.

The sending and receiving works fine in all other aspects. The object is created from a Unix socket. Is there any other aspect I need to set up for this function to correctly signal that there are bytes available to read?

gpoo
  • 8,408
  • 3
  • 38
  • 53
vbence
  • 20,084
  • 9
  • 69
  • 118

0 Answers0