From 8003e9544d92101c3fbb8220efe18cc135e8c380 Mon Sep 17 00:00:00 2001 From: Roberto Ierusalimschy Date: Mon, 19 Apr 2010 13:39:25 -0300 Subject: [PATCH] 'string.format' may get buffer as an argument when there are missing arguments and format string is too long --- bugs | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/bugs b/bugs index d82bedfd..430c8f7a 100644 --- a/bugs +++ b/bugs @@ -1880,8 +1880,8 @@ patch = [[ +++ lundump.c 2008/04/04 19:51:41 2.7.1.4 @@ -1,5 +1,5 @@ /* --** $Id: bugs,v 1.104 2009/08/05 13:09:38 roberto Exp roberto $ -+** $Id: bugs,v 1.104 2009/08/05 13:09:38 roberto Exp roberto $ +-** $Id: bugs,v 1.105 2009/11/23 14:59:30 roberto Exp roberto $ ++** $Id: bugs,v 1.105 2009/11/23 14:59:30 roberto Exp roberto $ ** load precompiled Lua chunks ** See Copyright Notice in lua.h */ @@ -2257,3 +2257,15 @@ patch = [[ ]] } +Bug{ +what = [['string.format' may get buffer as an argument when there are +missing arguments and format string is too long]], +report = [[Roberto I., 2010/04/12]], +since = [[5.0]], +example = [[ +x = string.rep("x", 10000) .. "%d" +print(string.format(x)) -- gives wrong error message +patch = [[ +]] +} +