Due to MessageConnectionTreeItem having a shared ptr to MessageConnection, a connection is never freed even after it closes, when the NetworkDialog is open. In a network client usage, this means leaking connections when performing repeated connection and disconnection.