From 30b818142929db197589b76aae62f2f7930f368b Mon Sep 17 00:00:00 2001 From: Spoike Date: Thu, 2 Sep 2004 12:59:35 +0000 Subject: [PATCH] make sure the functions works if the compiler aborted in the wrong place git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@114 fc73d0e0-1445-4013-8a0c-d673dee63da5 --- engine/qclib/QccMain.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/engine/qclib/QccMain.c b/engine/qclib/QccMain.c index 434c1a620..97be0b43e 100644 --- a/engine/qclib/QccMain.c +++ b/engine/qclib/QccMain.c @@ -1375,6 +1375,7 @@ called before compiling a batch of files, clears the pr struct */ void QCC_PR_BeginCompilation (void *memory, int memsize) { + extern int recursivefunctiontype; extern struct freeoffset_s *freeofs; int i; char name[16]; @@ -1436,6 +1437,7 @@ void QCC_PR_BeginCompilation (void *memory, int memsize) pr.types = NULL; // type_function->next = NULL; pr_error_count = 0; + recursivefunctiontype = 0; freeofs = NULL; } @@ -1478,7 +1480,7 @@ int QCC_PR_FinishCompilation (void) } else { - QCC_PR_Warning(WARN_NOTDEFINED, strings + d->s_file, d->s_line, "function %s was not defined\n",d->name); + QCC_PR_Warning(WARN_NOTDEFINED, strings + d->s_file, d->s_line, "function %s was not defined",d->name); bodylessfuncs = true; } // errors = true;