From 7442dc40a12bd61d6a77fafbc1ea031a2b51937a Mon Sep 17 00:00:00 2001 From: Marvin Borner Date: Thu, 21 Jan 2021 14:40:20 +0100 Subject: Fixed stray keyboard characters --- libc/stack.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'libc/stack.c') diff --git a/libc/stack.c b/libc/stack.c index dac18a2..c47dd59 100644 --- a/libc/stack.c +++ b/libc/stack.c @@ -117,3 +117,9 @@ void *stack_peek(struct stack *stack) return stack->tail; } + +void stack_clear(struct stack *stack) +{ + while (stack_pop(stack)) + ; +} -- cgit v1.2.3