Fix GCC 10.1 warnings

This commit is contained in:
Theo Arends 2020-07-15 14:11:41 +02:00
parent 23057c94ac
commit c66e5a4381
3 changed files with 9 additions and 4 deletions

View File

@ -1192,6 +1192,7 @@ int32_t Z_OccupancyCallback(uint16_t shortaddr, uint16_t groupaddr, uint16_t clu
JsonObject& json = jsonBuffer.createObject();
json[F(OCCUPANCY)] = 0;
zigbee_devices.jsonPublishNow(shortaddr, json);
return 0; // Fix GCC 10.1 warning
}
// Aqara Cube
@ -1420,6 +1421,7 @@ int32_t Z_ApplyConverter(const class ZCLFrame *zcl, uint16_t shortaddr, JsonObje
if (func) {
return (*func)(zcl, shortaddr, json, name, value, new_name, cluster, attr);
}
return 1; // Fix GCC 10.1 warning
}
void ZCLFrame::postProcessAttributes(uint16_t shortaddr, JsonObject& json) {

View File

@ -189,6 +189,7 @@ int32_t Z_ReadAttrCallback(uint16_t shortaddr, uint16_t groupaddr, uint16_t clus
}
ZigbeeZCLSend_Raw(shortaddr, groupaddr, cluster, endpoint, ZCL_READ_ATTRIBUTES, false, 0, attrs, attrs_len, true /* we do want a response */, zigbee_devices.getNextSeqNumber(shortaddr));
}
return 0; // Fix GCC 10.1 warning
}
@ -197,6 +198,7 @@ int32_t Z_Unreachable(uint16_t shortaddr, uint16_t groupaddr, uint16_t cluster,
if (BAD_SHORTADDR != shortaddr) {
zigbee_devices.setReachable(shortaddr, false); // mark device as reachable
}
return 0; // Fix GCC 10.1 warning
}
// set a timer to read back the value in the future

View File

@ -1217,6 +1217,7 @@ int32_t ZigbeeProcessInput(class SBuffer &buf) {
// any other negative value means error
ZigbeeGotoLabel(zigbee.on_error_goto);
}
return 0; // Fix GCC 10.1 warning
}
#endif // USE_ZIGBEE