mirror of
https://github.com/meshtastic/firmware.git
synced 2025-06-08 22:22:05 +00:00
udp-multicast: do not listen for incoming udp multicast packets if disabled (#6397)
Currently the config flag only control if packets are sent, not received. As we discussed in VC this is not what was intended.
This commit is contained in:
parent
13101c1bab
commit
6429eca5e4
@ -829,7 +829,9 @@ void setup()
|
|||||||
#ifdef ARCH_PORTDUINO
|
#ifdef ARCH_PORTDUINO
|
||||||
// FIXME: portduino does not ever call onNetworkConnected so call it here because I don't know what happen if I call
|
// FIXME: portduino does not ever call onNetworkConnected so call it here because I don't know what happen if I call
|
||||||
// onNetworkConnected there
|
// onNetworkConnected there
|
||||||
|
if (config.network.enabled_protocols & meshtastic_Config_NetworkConfig_ProtocolFlags_UDP_BROADCAST) {
|
||||||
udpThread->start();
|
udpThread->start();
|
||||||
|
}
|
||||||
#endif
|
#endif
|
||||||
#endif
|
#endif
|
||||||
service = new MeshService();
|
service = new MeshService();
|
||||||
|
@ -133,7 +133,7 @@ static void onNetworkConnected()
|
|||||||
}
|
}
|
||||||
|
|
||||||
#if HAS_UDP_MULTICAST
|
#if HAS_UDP_MULTICAST
|
||||||
if (udpThread) {
|
if (udpThread && config.network.enabled_protocols & meshtastic_Config_NetworkConfig_ProtocolFlags_UDP_BROADCAST) {
|
||||||
udpThread->start();
|
udpThread->start();
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
Reference in New Issue
Block a user