test/bluetooth: sizeof() is not strlen()
sizeof(value) returns the size of the pointer, not the pointed string. Signed-off-by: Nicolas Pitre <npitre@baylibre.com> tests/bluetooth/gatt/src/main.c
This commit is contained in:
parent
9e57338efd
commit
2dc6eea143
1 changed files with 1 additions and 1 deletions
|
@ -260,7 +260,7 @@ void test_gatt_write(void)
|
|||
zassert_not_null(attr, "Attribute don't match");
|
||||
|
||||
ret = attr->write(NULL, attr, (void *)value, strlen(value), 0, 0);
|
||||
zassert_equal(ret, sizeof(value), "Attribute write unexpected return");
|
||||
zassert_equal(ret, strlen(value), "Attribute write unexpected return");
|
||||
zassert_mem_equal(value, test_value, ret,
|
||||
"Attribute write value don't match");
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue