Enabled style and CERT-C addon for CPPCHECK (#869)
* Enabled style and CERT-C addon for CPPCHECK with some suppressions and fixed the defects found..
This commit is contained in:
@@ -738,7 +738,7 @@ size_t bvlc_sc_encode_result(
|
||||
uint8_t *error_header_marker,
|
||||
uint16_t *error_class,
|
||||
uint16_t *error_code,
|
||||
uint8_t *utf8_details_string)
|
||||
const uint8_t *utf8_details_string)
|
||||
{
|
||||
size_t offs;
|
||||
|
||||
@@ -1803,7 +1803,7 @@ static bool bvlc_sc_decode_hdr(
|
||||
offs += hdr_opt_len;
|
||||
}
|
||||
|
||||
if (message_len - offs <= 0) {
|
||||
if (offs >= message_len) {
|
||||
/* no payload */
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user