Replace g_object_unref() with g_io_channel_unref() for GIOChannel objects.

An GIOChannel object should be freed with g_io_channel_unref().
The previous code wrongly uses g_object_unref() for it.