From a8c9eec4260ced4aa69048d92766d55026135b22 Mon Sep 17 00:00:00 2001 From: Roberto Ierusalimschy Date: Wed, 10 Jul 2002 17:43:53 -0300 Subject: [PATCH] bug: chunk can end just after a '\' in a string --- llex.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/llex.c b/llex.c index 7030e62d..27f11134 100644 --- a/llex.c +++ b/llex.c @@ -1,5 +1,5 @@ /* -** $Id: llex.c,v 1.106 2002/06/25 19:18:20 roberto Exp roberto $ +** $Id: llex.c,v 1.107 2002/07/08 18:14:36 roberto Exp roberto $ ** Lexical Analyzer ** See Copyright Notice in lua.h */ @@ -273,6 +273,7 @@ static void read_string (LexState *LS, int del, SemInfo *seminfo) { case 't': save(L, '\t', l); next(LS); break; case 'v': save(L, '\v', l); next(LS); break; case '\n': save(L, '\n', l); inclinenumber(LS); break; + case EOZ: break; /* will raise an error next loop */ default: { if (!isdigit(LS->current)) save_and_next(L, LS, l); /* handles \\, \", \', and \? */