Fix closing unbuffered Ring/Overflowing-Channels.

We need to close the output channel in those cases, or else (for example) a loop
ranging over it will never end, resulting in deadlock.