bugfix: the TcpSocket needs to check if the device is closed after checking the poll events and emit the `closed` signal then.
bugfix: the TcpSocket needs to check if the device is closed after checking the poll events
and emit the `closed` signal then.

maekitalo/cxxtools,maekitalo/cxxtools,maekitalo/cxxtools,maekitalo/cxxtools