SSL.File: Improved robustness of close handling.

The close_state is now set correctly even when there's a pending
close_errno and the peer closes the connection.
cpp(): added documentation