posixFileWriteChannel

fun posixFileWriteChannel(fd: Int): ByteWriteChannel

Creates a ByteWriteChannel that will write bytes to the specified file descriptor fd.

This is accomplished by creating a dedicated thread that blocks on reads before queueing to a ByteChannel for suspended reading, so only use when needed.