summaryrefslogtreecommitdiff
path: root/perly.c
diff options
context:
space:
mode:
Diffstat (limited to 'perly.c')
-rw-r--r--perly.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/perly.c b/perly.c
index 36f78a346b..af09290581 100644
--- a/perly.c
+++ b/perly.c
@@ -195,7 +195,7 @@ S_clear_yystack(pTHX_ const yy_parser *parser)
yy_stack_frame *ps = parser->ps;
int i;
- if (ps == parser->stack)
+ if (!parser->stack || ps == parser->stack)
return;
YYDPRINTF ((Perl_debug_log, "clearing the parse stack\n"));