mirror of
https://github.com/opnsense/src.git
synced 2026-06-08 16:22:46 -04:00
Ensure we read existing values of the stk table
Obtained from: NetBSD
This commit is contained in:
parent
0a2963a2ac
commit
ca887f8d07
1 changed files with 4 additions and 2 deletions
|
|
@ -341,7 +341,8 @@ process(FILE *f)
|
|||
n = 10 * n + line[i] - '0';
|
||||
i--;
|
||||
if (n == 0) {
|
||||
if (stk[stktop].opno == SZ) {
|
||||
if (stktop >= 0 &&
|
||||
stk[stktop].opno == SZ) {
|
||||
stktop--;
|
||||
} else {
|
||||
pe(lineno);
|
||||
|
|
@ -356,7 +357,8 @@ process(FILE *f)
|
|||
} else if (!fflag && line[i] == 'f') {
|
||||
n = line[++i];
|
||||
if (n == 'P') {
|
||||
if (stk[stktop].opno == FT) {
|
||||
if (stktop >= 0 &&
|
||||
stk[stktop].opno == FT) {
|
||||
stktop--;
|
||||
} else {
|
||||
pe(lineno);
|
||||
|
|
|
|||
Loading…
Reference in a new issue