From ca13be9af784b7288d3a07d9b5bccb329086e885 Mon Sep 17 00:00:00 2001 From: Roberto Ierusalimschy Date: Fri, 16 Aug 2019 09:51:54 -0300 Subject: Supressed errors in '__close' generate warnings --- lauxlib.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lauxlib.c') diff --git a/lauxlib.c b/lauxlib.c index ba1980b7..014e7052 100644 --- a/lauxlib.c +++ b/lauxlib.c @@ -1010,9 +1010,9 @@ static int panic (lua_State *L) { static void warnf (void *ud, const char *message, int tocont) { int *warnstate = (int *)ud; if (*warnstate != 2 && !tocont && *message == '@') { /* control message? */ - if (strcmp(message + 1, "off") == 0) + if (strcmp(message, "@off") == 0) *warnstate = 0; - else if (strcmp(message + 1, "on") == 0) + else if (strcmp(message, "@on") == 0) *warnstate = 1; return; } -- cgit v1.2.3-55-g6feb