diff --git a/packages/moxxmpp/lib/src/connection.dart b/packages/moxxmpp/lib/src/connection.dart index 3d01536..09d3366 100644 --- a/packages/moxxmpp/lib/src/connection.dart +++ b/packages/moxxmpp/lib/src/connection.dart @@ -397,6 +397,9 @@ class XmppConnection { return; } + // Close the socket + _socket.close(); + if (!error.isRecoverable()) { // We cannot recover this error _log.severe(