Differentiate between number of reflectors and parrot

This commit is contained in:
phl0 2016-10-18 11:25:25 +02:00
parent f58bf29080
commit 7c9ff0b672
1 changed files with 7 additions and 6 deletions

View File

@ -88,6 +88,12 @@ bool CReflectors::load()
::fclose(fp);
}
size_t size = m_reflectors.size();
if (size == 0U)
return false;
LogInfo("Loaded %u P25 reflectors", size);
// Add the Parrot entry
if (m_parrotPort > 0U) {
CP25Reflector* refl = new CP25Reflector;
@ -95,14 +101,9 @@ bool CReflectors::load()
refl->m_address = CUDPSocket::lookup(m_parrotAddress);
refl->m_port = m_parrotPort;
m_reflectors.push_back(refl);
LogInfo("Loaded P25 parrot");
}
size_t size = m_reflectors.size();
if (size == 0U)
return false;
LogInfo("Loaded %u P25 reflectors", size);
return true;
}