vchan: check for `Eof in the inner loops of read, write and writev

Previously we only checked the connection state on entry, but then would
block forever waiting for data to arrive. We would be signalled on close
but not re-check the state.

We now always check the state.

Signed-off-by: David Scott <dave.scott@eu.citrix.com>
xencat: while proxying, End_of_file means we should shutdown cleanly

There is one proxy thread for each direction. When one of these threads
gets End_of_file, it should unblock, shutdown the connection and cleanup.

Signed-off-by: David Scott <dave.scott@eu.citrix.com>
Merge pull request #30 from djs55/test

Handle `Eof while blocked in read/write