From 4e47db02111fcb057c69c96bb31bf93e50f2a06a Mon Sep 17 00:00:00 2001 From: Larry Frieson Date: Tue, 9 Aug 2022 21:24:32 -0700 Subject: [PATCH] Fix destroyStack() function in cnex --- exec/cnex/stack.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/exec/cnex/stack.c b/exec/cnex/stack.c index 19546e04ec..17d004488c 100644 --- a/exec/cnex/stack.c +++ b/exec/cnex/stack.c @@ -29,7 +29,7 @@ TStack *createStack(int capacity) void destroyStack(TStack *stack) { - while (stack->top > 0) { + while (stack->top != -1) { pop(stack); }