fixed bug amb259
--HG-- extra : convert_revision : svn%3A39bc706e-5318-0410-9160-8a85361fbb7c/trunk%40751
This commit is contained in:
parent
16fa9e0fa6
commit
b8e2b6cf68
@ -3985,7 +3985,7 @@ static int newfunc(char *firstname,int firsttag,int fpublic,int fstatic,int stoc
|
||||
if (matchtoken(';')) {
|
||||
sym->usage|=uFORWARD;
|
||||
if (!sc_needsemicolon)
|
||||
error(218); /* old style prototypes used with optional semicolumns */
|
||||
error(10); /* old style prototypes used with optional semicolumns */
|
||||
delete_symbols(&loctab,0,TRUE,TRUE); /* prototype is done; forget everything */
|
||||
return TRUE;
|
||||
} /* if */
|
||||
|
@ -2674,9 +2674,12 @@ static int nesting=0;
|
||||
if ((sym->usage & uNATIVE)==0)
|
||||
totalsize++; /* add "call" opcode */
|
||||
totalsize+=nest_stkusage;
|
||||
assert(curfunc!=NULL);
|
||||
if (curfunc->x.stacksize<totalsize)
|
||||
curfunc->x.stacksize=totalsize;
|
||||
if (curfunc != NULL) {
|
||||
if (curfunc->x.stacksize<totalsize)
|
||||
curfunc->x.stacksize=totalsize;
|
||||
} else {
|
||||
error(10);
|
||||
}
|
||||
nest_stkusage-=nargs+heapalloc+1; /* stack/heap space, +1 for argcount param */
|
||||
/* if there is a syntax error in the script, the stack calculation is
|
||||
* probably incorrect; but we may not allow it to drop below zero
|
||||
|
Loading…
Reference in New Issue
Block a user