Skip to content

Commit 7d7a317

Browse files
Jeppe Odgaardcfriedt
authored andcommitted
lib: heap: return -ENOMEM if heap_array is full
Replace -EINVAL which indicates an invalid input parameter. Signed-off-by: Jeppe Odgaard <[email protected]>
1 parent 24669df commit 7d7a317

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/heap/heap_array.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ int sys_heap_array_save(struct sys_heap *heap)
1818
if (i < CONFIG_SYS_HEAP_ARRAY_SIZE) {
1919
heaps[i++] = heap;
2020
} else {
21-
return -EINVAL;
21+
return -ENOMEM;
2222
}
2323

2424
return 0;

0 commit comments

Comments
 (0)