2
0
mirror of https://github.com/sudo-project/sudo.git synced 2025-08-31 06:15:37 +00:00
This commit is contained in:
Todd C. Miller
2013-11-04 10:30:12 -07:00
parent 8e503a229f
commit e8dac0e4ab
2 changed files with 8 additions and 6 deletions

View File

@@ -1016,8 +1016,9 @@ static int yygrowstack()
short *newss;
YYSTYPE *newvs;
newsize = yystacksize ? yystacksize : YYINITSTACKSIZE;
if (newsize >= YYMAXDEPTH)
if ((newsize = yystacksize) == 0)
newsize = YYINITSTACKSIZE;
else if (newsize >= YYMAXDEPTH)
return -1;
else if ((newsize *= 2) > YYMAXDEPTH)
newsize = YYMAXDEPTH;
@@ -1500,7 +1501,7 @@ case 41:
yyval.Meridian = yyvsp[0].Meridian;
}
break;
#line 1451 "getdate.c"
#line 1452 "getdate.c"
}
yyssp -= yym;
yystate = *yyssp;

View File

@@ -971,8 +971,9 @@ static int yygrowstack()
short *newss;
YYSTYPE *newvs;
newsize = yystacksize ? yystacksize : YYINITSTACKSIZE;
if (newsize >= YYMAXDEPTH)
if ((newsize = yystacksize) == 0)
newsize = YYINITSTACKSIZE;
else if (newsize >= YYMAXDEPTH)
return -1;
else if ((newsize *= 2) > YYMAXDEPTH)
newsize = YYMAXDEPTH;
@@ -1849,7 +1850,7 @@ case 111:
yyval.member = new_member(yyvsp[0].string, WORD);
}
break;
#line 1800 "gram.c"
#line 1801 "gram.c"
}
yyssp -= yym;
yystate = *yyssp;