iot/zoap: Fix comparing pointers of different signedness
strncmp() expects pointers of type 'char *', we could cast option.value to 'char *', but we can use memcmp() instead, which has the benefit of being simpler. Change-Id: I8c4ee4401712f3617c134d8e5b6d84e8f5cc4e1d Signed-off-by: Vinicius Costa Gomes <vinicius.gomes@intel.com>
This commit is contained in:
parent
e965119cd9
commit
75d7147fa4
1 changed files with 1 additions and 1 deletions
|
@ -504,7 +504,7 @@ static bool uri_path_eq(const struct zoap_packet *pkt,
|
|||
return false;
|
||||
}
|
||||
|
||||
if (strncmp(options[i].value, path[i], len)) {
|
||||
if (memcmp(options[i].value, path[i], len)) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue