summaryrefslogtreecommitdiffhomepage
path: root/src/parse.y
diff options
context:
space:
mode:
Diffstat (limited to 'src/parse.y')
-rw-r--r--src/parse.y4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/parse.y b/src/parse.y
index 90a0eeb3b..7694644a9 100644
--- a/src/parse.y
+++ b/src/parse.y
@@ -3342,7 +3342,7 @@ newtok(parser_state *p)
static void
tokadd(parser_state *p, int c)
{
- if (p->bidx < 1024) {
+ if (p->bidx < MRB_PARSER_BUF_SIZE) {
p->buf[p->bidx++] = c;
}
}
@@ -3356,7 +3356,7 @@ toklast(parser_state *p)
static void
tokfix(parser_state *p)
{
- if (p->bidx >= 1024) {
+ if (p->bidx >= MRB_PARSER_BUF_SIZE) {
yyerror(p, "string too long (truncated)");
}
p->buf[p->bidx] = '\0';