k_stack_init: num_entries should be unsigned

Allowing negative values here is a great way to get the kernel to
explode.

Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
This commit is contained in:
Andrew Boie 2017-10-12 14:01:25 -07:00 committed by Andrew Boie
commit 8e3e6d0d79
2 changed files with 4 additions and 7 deletions

View file

@ -2000,7 +2000,7 @@ struct k_stack {
* @return N/A
*/
__syscall void k_stack_init(struct k_stack *stack,
u32_t *buffer, int num_entries);
u32_t *buffer, unsigned int num_entries);
/**
* @brief Push an element onto a stack.