mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-04-23 15:00:02 +02:00
minor. removed warning print at startup for empty eth udp to listen to (#992)
This commit is contained in:
parent
f2f3817a7f
commit
45957391a6
@ -805,7 +805,7 @@ void Implementation::stopReceiver() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
TLogLevel lev = ((mp[i]) > 0) ? logINFORED : logINFOGREEN;
|
TLogLevel lev = ((mp[i]) > 0) ? logINFORED : logINFOGREEN;
|
||||||
LOG(lev) << "Summary of Port " << udpPortNum[i] << summary;
|
LOG(lev) << "Summary of Port " << udpPortNum[i] << " (" << eth[i] << ')' << summary;
|
||||||
}
|
}
|
||||||
|
|
||||||
// callback
|
// callback
|
||||||
|
@ -81,10 +81,6 @@ void Listener::SetEthernetInterface(const std::string e) {
|
|||||||
if (eth.find('.') != std::string::npos) {
|
if (eth.find('.') != std::string::npos) {
|
||||||
eth = "";
|
eth = "";
|
||||||
}
|
}
|
||||||
if (!eth.length()) {
|
|
||||||
LOG(logWARNING) << "ethernet interface for udp port " << udpPortNumber
|
|
||||||
<< " is empty. Listening to all";
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void Listener::SetActivate(bool enable) {
|
void Listener::SetActivate(bool enable) {
|
||||||
@ -153,12 +149,13 @@ void Listener::CreateUDPSocket(int &actualSize) {
|
|||||||
packetSize = generalData->vetoPacketSize;
|
packetSize = generalData->vetoPacketSize;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
std::string ip = (eth.length() ? InterfaceNameToIp(eth).str().c_str() : "");
|
||||||
|
|
||||||
udpSocket = nullptr;
|
udpSocket = nullptr;
|
||||||
udpSocket = make_unique<UdpRxSocket>(
|
udpSocket = make_unique<UdpRxSocket>(
|
||||||
udpPortNumber, packetSize,
|
udpPortNumber, packetSize, (ip.length() ? ip.c_str() : nullptr),
|
||||||
(eth.length() ? InterfaceNameToIp(eth).str().c_str() : nullptr),
|
|
||||||
generalData->udpSocketBufferSize);
|
generalData->udpSocketBufferSize);
|
||||||
LOG(logINFO) << index << ": UDP port opened at port " << udpPortNumber;
|
LOG(logINFO) << index << ": UDP port opened at port " << udpPortNumber << " (" << (ip.length() ? ip : "any") << ')';
|
||||||
|
|
||||||
udpSocketAlive = true;
|
udpSocketAlive = true;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user