Skip to content


Thomas Haller requested to merge th/unix-fd-source into master

We don't need an GIOChannel to watch a file descriptor.

It's well understood what file descriptors are, and that we want to poll/select on them to know when there is something ready. We don't need an GIOChannel for that, just watch the fd directly.

On a minor point, this reduces some overhead of also creating a unnecessary GIOChannel.

The larger point is that watching a file descriptor alone is simple and clear. It's not clear what the GIOChannel does (e.g. it has code for handing text encoding and uses buffers). It just adds a lot of additional code and API that we don't need nor want.

Merge request reports