From 1007ce4cd945b73b6610f70cbde8bd8ea5a2a477 Mon Sep 17 00:00:00 2001 From: nishi Date: Tue, 23 Apr 2024 06:22:51 +0000 Subject: [PATCH] parsing segfaults git-svn-id: file:///raid/svn-main/nishi-serenade/trunk@16 0f02c867-ac3d-714e-8a88-971ba1f6efcf --- Serenade/parser.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Serenade/parser.c b/Serenade/parser.c index 3fd3b11..a3ae6a2 100644 --- a/Serenade/parser.c +++ b/Serenade/parser.c @@ -116,7 +116,7 @@ struct sn_generic* sn_expr_parse(char* data, unsigned long long size){ gn_stack[br - 1]->tree->op->name = sn_strdup(op_stack[br - 1]); } br_stack[br - 1] = 0; - PUSH_STACK(br - 1); + PUSH_STACK(br - 2); if(br_stack[br - 2] > 0){ int j; struct sn_generic** old_args = gn_stack[br - 2]->tree->args; -- 2.43.0