diff --git a/test/system/zephyr/alloc.c b/test/system/zephyr/alloc.c index e3b86df..2944b62 100644 --- a/test/system/zephyr/alloc.c +++ b/test/system/zephyr/alloc.c @@ -7,6 +7,7 @@ #include #include +#include #include #include #include @@ -19,7 +20,7 @@ static int alloc(void) ptr = metal_allocate_memory(1000); if (!ptr) { metal_log(METAL_LOG_DEBUG, "failed to allocate memmory\n"); - return errno; + return -errno; } metal_free_memory(ptr);