We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 23e5d5f + a6301f8 commit 5a0d773Copy full SHA for 5a0d773
libraries/MySensors/MySensor.cpp
@@ -353,9 +353,10 @@ boolean MySensor::process() {
353
if (repeaterMode && msg.getString()[0] == 'C') {
354
// Clears child relay data for this node
355
debug(PSTR("rd=clear\n"));
356
- for (uint8_t i=0;i< 256; i++) {
+ uint8_t i = 255;
357
+ do {
358
removeChildRoute(i);
- }
359
+ } while (i--);
360
// Clear parent node id & distance to gw
361
eeprom_write_byte((uint8_t*)EEPROM_PARENT_NODE_ID_ADDRESS, 0xFF);
362
eeprom_write_byte((uint8_t*)EEPROM_DISTANCE_ADDRESS, 0xFF);
0 commit comments