Resolved various compiler warnings
This should make Jenkins happy.
This commit is contained in:
@@ -79,7 +79,7 @@ int16_t SNEP::read(uint8_t *buf, uint8_t len, uint16_t timeout)
|
||||
}
|
||||
|
||||
// check message's length
|
||||
uint32_t length = (buf[2] << 24) + (buf[3] << 16) + (buf[4] << 8) + buf[5];
|
||||
uint32_t length = ((uint32_t)buf[2] << 24) + ((uint32_t)buf[3] << 16) + (buf[4] << 8) + buf[5];
|
||||
// length should not be more than 244 (header + body < 255, header = 6 + 3 + 2)
|
||||
if (length > (status - 6)) {
|
||||
DMSG("The SNEP message is too large\n");
|
||||
|
||||
Reference in New Issue
Block a user