mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-19 22:48:18 +00:00
skip duplicate error string. Closes #1339
This commit is contained in:
parent
6722e8e3b1
commit
014f77eefc
|
@ -187,9 +187,13 @@ void CNetConnection::Disconnect(const char *pReason)
|
||||||
else
|
else
|
||||||
SendControl(NET_CTRLMSG_CLOSE, 0, 0);
|
SendControl(NET_CTRLMSG_CLOSE, 0, 0);
|
||||||
|
|
||||||
m_ErrorString[0] = 0;
|
if(pReason != m_ErrorString)
|
||||||
if(pReason)
|
{
|
||||||
str_copy(m_ErrorString, pReason, sizeof(m_ErrorString));
|
if(pReason)
|
||||||
|
str_copy(m_ErrorString, pReason, sizeof(m_ErrorString));
|
||||||
|
else
|
||||||
|
m_ErrorString[0] = 0;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Reset();
|
Reset();
|
||||||
|
|
Loading…
Reference in a new issue