mirror of
https://github.com/znc/znc.git
synced 2026-05-08 14:24:45 +02:00
Some small cleanup to CUser::Clone()
This shouldn't change anything except the readers ability to understand this snippet (hopefully). git-svn-id: https://znc.svn.sourceforge.net/svnroot/znc/trunk@1658 726aef4b-f618-498e-8847-2d620e286838
This commit is contained in:
@@ -379,20 +379,20 @@ bool CUser::Clone(const CUser& User, CString& sErrorRet, bool bCloneChans) {
|
||||
AddServer(pServer->GetName(), pServer->GetPort(), pServer->GetPass(), pServer->IsSSL());
|
||||
}
|
||||
|
||||
m_uServerIdx = 0;
|
||||
for (a = 0; a < m_vServers.size(); a++) {
|
||||
if (sServer.Equals(m_vServers[a]->GetName())) {
|
||||
m_uServerIdx = a +1;
|
||||
m_uServerIdx = a + 1;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (m_uServerIdx == 0) {
|
||||
m_uServerIdx = m_vServers.size();
|
||||
CIRCSock* pSock = GetIRCSock();
|
||||
|
||||
if (a == m_vServers.size() -1) {
|
||||
m_uServerIdx = m_vServers.size();
|
||||
CIRCSock* pSock = GetIRCSock();
|
||||
|
||||
if (pSock) {
|
||||
PutStatus("Jumping servers because this server is no longer in the list");
|
||||
pSock->Quit();
|
||||
}
|
||||
if (pSock) {
|
||||
PutStatus("Jumping servers because this server is no longer in the list");
|
||||
pSock->Quit();
|
||||
}
|
||||
}
|
||||
// !Servers
|
||||
|
||||
@@ -278,7 +278,7 @@ protected:
|
||||
set<CDCCBounce*> m_sDCCBounces;
|
||||
set<CDCCSock*> m_sDCCSocks;
|
||||
set<CString> m_ssAllowedHosts;
|
||||
unsigned int m_uServerIdx;
|
||||
unsigned int m_uServerIdx; ///< Index in m_vServers of our current server + 1
|
||||
unsigned int m_uBufferCount;
|
||||
unsigned long long m_uBytesRead;
|
||||
unsigned long long m_uBytesWritten;
|
||||
|
||||
Reference in New Issue
Block a user