Add connectionGetLine, and improve EOF handling

Thanks for following up on EOF semantics.  This pull request adds `connectionGetLine`, and improves EOF handling a little more:

 * Don't check EOF for `connectionPut`.  If the peer signals EOF using `shutdown(SD_SEND)` or TLS `bye`, it can still wait for us to finish sending our data.

 * Change `connectionBuffer` to `MVar (Maybe ByteString)`, and use it to signal EOF.  This avoids having to go through another MVar, and forces us to check for EOF every time we perform a get operation.