aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lstrlib.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/lstrlib.c b/lstrlib.c
index 3e89981d..6cd07ebd 100644
--- a/lstrlib.c
+++ b/lstrlib.c
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: lstrlib.c,v 1.194 2014/04/10 19:45:43 roberto Exp roberto $ 2** $Id: lstrlib.c,v 1.195 2014/04/12 14:45:10 roberto Exp roberto $
3** Standard library for string operations and pattern-matching 3** Standard library for string operations and pattern-matching
4** See Copyright Notice in lua.h 4** See Copyright Notice in lua.h
5*/ 5*/
@@ -104,8 +104,8 @@ static int str_upper (lua_State *L) {
104 104
105 105
106/* reasonable limit to avoid arithmetic overflow and strings too big */ 106/* reasonable limit to avoid arithmetic overflow and strings too big */
107#if INT_MAX / 2 <= 0x10000000 107#if LUA_MAXINTEGER / 2 <= 0x10000000
108#define MAXSIZE ((size_t)(INT_MAX / 2)) 108#define MAXSIZE ((size_t)(LUA_MAXINTEGER / 2))
109#else 109#else
110#define MAXSIZE ((size_t)0x10000000) 110#define MAXSIZE ((size_t)0x10000000)
111#endif 111#endif