fix removing...disappeared msg with wrong ip/port

This commit is contained in:
narspt 2019-04-07 13:07:58 +01:00 committed by GitHub
parent 9495bb203b
commit 494c33103b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -285,7 +285,7 @@ void CYSFReflector::run()
for (std::vector<CYSFRepeater*>::iterator it = m_repeaters.begin(); it != m_repeaters.end(); ++it) {
CYSFRepeater* itRpt = *it;
if (itRpt->m_timer.hasExpired()) {
LogMessage("Removing %s (%s:%u) disappeared", itRpt->m_callsign.c_str(), ::inet_ntoa(address), port);
LogMessage("Removing %s (%s:%u) disappeared", itRpt->m_callsign.c_str(), ::inet_ntoa(itRpt->m_address), itRpt->m_port);
m_repeaters.erase(it);
delete itRpt;
network.setCount(m_repeaters.size());