From 435f587ed05e2c4d542e1db9ae9e4efbb7e02305 Mon Sep 17 00:00:00 2001 From: Roberto Ierusalimschy Date: Fri, 4 Aug 2000 16:38:35 -0300 Subject: (much) better handling of memory alloction errors --- lcode.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'lcode.c') diff --git a/lcode.c b/lcode.c index c80ea0da..fd7c6683 100644 --- a/lcode.c +++ b/lcode.c @@ -1,5 +1,5 @@ /* -** $Id: lcode.c,v 1.40 2000/06/28 20:20:36 roberto Exp roberto $ +** $Id: lcode.c,v 1.41 2000/06/30 14:35:17 roberto Exp roberto $ ** Code generator for Lua ** See Copyright Notice in lua.h */ @@ -620,8 +620,8 @@ int luaK_code2 (FuncState *fs, OpCode o, int arg1, int arg2) { } if (fs->debug) { LexState *ls = fs->ls; - luaX_checklimit(ls, ls->lastline, MAXARG_U, "lines in a chunk"); - luaM_growvector(fs->L, fs->f->lines, fs->pc, 1, int, "??", MAXARG_U); + luaM_growvector(fs->L, fs->f->lines, fs->pc, 1, int, + "code size overflow", MAX_INT); fs->f->lines[fs->pc] = ls->lastline; } /* put new instruction in code array */ -- cgit v1.2.3-55-g6feb