Commit ed7fb754 authored by Flavio Ceolin's avatar Flavio Ceolin Committed by Anas Nashif
Browse files

tests: hwinfo: Fix invalid assertion



The return of hwinfo_get_device_id is a signed size and it returns a
negative number in case of error. This test was using an unsigned
variable invalidating the errror check.

CID 190929

Signed-off-by: default avatarFlavio Ceolin <flavio.ceolin@intel.com>
parent 6b4cda9b
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -34,7 +34,7 @@ static void test_device_id_get(void)
{
	u8_t buffer_1[BUFFER_LENGTH];
	u8_t buffer_2[BUFFER_LENGTH];
	size_t length_read_1, length_read_2;
	ssize_t length_read_1, length_read_2;
	int i;

	length_read_1 = hwinfo_get_device_id(buffer_1, 1);