Fix error description.
Add timeout detection and handling on `connect`.
Add timeout detection and handling on `close`.
Merge branch 'timeout'