diff --git a/src/lib/plugin/ns/SecureListenSocket.cpp b/src/lib/plugin/ns/SecureListenSocket.cpp index 562a6899..86907608 100644 --- a/src/lib/plugin/ns/SecureListenSocket.cpp +++ b/src/lib/plugin/ns/SecureListenSocket.cpp @@ -55,7 +55,6 @@ SecureListenSocket::accept() m_socketMultiplexer, ARCH->acceptSocket(m_socket, NULL)); socket->initSsl(true); - m_secureSocketSet.insert(socket); if (socket != NULL) { setListeningJob(); @@ -78,6 +77,8 @@ SecureListenSocket::accept() socket->secureAccept(); + m_secureSocketSet.insert(socket); + return dynamic_cast(socket); } catch (XArchNetwork&) {