Fixed double delete on legacy network error
This commit is contained in:
parent
c6224941ce
commit
25f5516757
3 changed files with 9 additions and 3 deletions
|
@ -77,6 +77,10 @@ class UserManager {
|
|||
return m_users.find(barejid) != m_users.end();
|
||||
}
|
||||
|
||||
UserRegistry *getUserRegistry() {
|
||||
return m_userRegistry;
|
||||
}
|
||||
|
||||
void connectUser(const Swift::JID &user);
|
||||
|
||||
private:
|
||||
|
|
|
@ -13,8 +13,8 @@ admin_password=test
|
|||
users_per_backend=2
|
||||
backend=../../backends/libpurple/spectrum_libpurple_backend
|
||||
#backend=../../backends/libircclient-qt/spectrum_libircclient-qt_backend
|
||||
protocol=prpl-jabber
|
||||
#protocol=prpl-msn
|
||||
#protocol=prpl-jabber
|
||||
protocol=prpl-msn
|
||||
#protocol=prpl-icq
|
||||
|
||||
[logging]
|
||||
|
|
|
@ -191,7 +191,9 @@ void User::handleDisconnected(const std::string &error) {
|
|||
// Once in finishSession and once in m_userManager->removeUser.
|
||||
if (m_component->inServerMode()) {
|
||||
dynamic_cast<Swift::ServerStanzaChannel *>(m_component->getStanzaChannel())->finishSession(m_jid, boost::shared_ptr<Swift::Element>(new Swift::StreamError()));
|
||||
m_userManager->removeUser(this);
|
||||
if (!m_readyForConnect) {
|
||||
m_userManager->removeUser(this);
|
||||
}
|
||||
}
|
||||
else {
|
||||
m_userManager->removeUser(this);
|
||||
|
|
Loading…
Add table
Reference in a new issue