/* Returns: the flags which are set on the channel  */
GIOFlags g_io_channel_get_flags(GIOChannel *channel)
/* Returns: the flags which are set on the channel  */
GIOFlags g_io_channel_get_flags(GIOChannel *channel)
{
  GIOFlags flags;
  g_return_val_if_fail (channel != NULL, 0);
  flags = (* channel->funcs->io_get_flags) (channel);
  if (channel->is_seekable)
    flags |= G_IO_FLAG_IS_SEEKABLE;
  if (channel->is_readable)
    flags |= G_IO_FLAG_IS_READABLE;
  if (channel->is_writeable)
    flags |= G_IO_FLAG_IS_WRITABLE;
  return flags;
}