From e3953be8f8d7911052ecc08d6f2baa2d00a4e9e9 Mon Sep 17 00:00:00 2001 From: Bill Currie Date: Tue, 25 Feb 2020 15:19:21 +0900 Subject: [PATCH] Ensure execution state is initialized on progs load --- libs/gamecode/pr_load.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/libs/gamecode/pr_load.c b/libs/gamecode/pr_load.c index 2b6e9d9ff..efa347f4b 100644 --- a/libs/gamecode/pr_load.c +++ b/libs/gamecode/pr_load.c @@ -330,6 +330,12 @@ PR_LoadProgsFile (progs_t *pr, QFile *file, int size) def->type_encoding = xdef->type; } } + pr->pr_trace = 0; + pr->pr_trace_depth = 0; + pr->pr_xfunction = 0; + pr->pr_xstatement = 0; + pr->pr_depth = 0; + pr->localstack_used = 0; } VISIBLE void