diff options
Diffstat (limited to 'lua.c')
-rw-r--r-- | lua.c | 14 |
1 files changed, 7 insertions, 7 deletions
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | ** $Id: lua.c,v 1.205 2012/05/23 15:37:09 roberto Exp roberto $ | 2 | ** $Id: lua.c,v 1.206 2012/09/29 20:07:06 roberto Exp roberto $ |
3 | ** Lua stand-alone interpreter | 3 | ** Lua stand-alone interpreter |
4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
5 | */ | 5 | */ |
@@ -31,12 +31,12 @@ | |||
31 | #define LUA_MAXINPUT 512 | 31 | #define LUA_MAXINPUT 512 |
32 | #endif | 32 | #endif |
33 | 33 | ||
34 | #if !defined(LUA_INIT) | 34 | #if !defined(LUA_INIT_VAR) |
35 | #define LUA_INIT "LUA_INIT" | 35 | #define LUA_INIT_VAR "LUA_INIT" |
36 | #endif | 36 | #endif |
37 | 37 | ||
38 | #define LUA_INITVERSION \ | 38 | #define LUA_INITVARVERSION \ |
39 | LUA_INIT "_" LUA_VERSION_MAJOR "_" LUA_VERSION_MINOR | 39 | LUA_INIT_VAR "_" LUA_VERSION_MAJOR "_" LUA_VERSION_MINOR |
40 | 40 | ||
41 | 41 | ||
42 | /* | 42 | /* |
@@ -421,10 +421,10 @@ static int runargs (lua_State *L, char **argv, int n) { | |||
421 | 421 | ||
422 | 422 | ||
423 | static int handle_luainit (lua_State *L) { | 423 | static int handle_luainit (lua_State *L) { |
424 | const char *name = "=" LUA_INITVERSION; | 424 | const char *name = "=" LUA_INITVARVERSION; |
425 | const char *init = getenv(name + 1); | 425 | const char *init = getenv(name + 1); |
426 | if (init == NULL) { | 426 | if (init == NULL) { |
427 | name = "=" LUA_INIT; | 427 | name = "=" LUA_INIT_VAR; |
428 | init = getenv(name + 1); /* try alternative name */ | 428 | init = getenv(name + 1); /* try alternative name */ |
429 | } | 429 | } |
430 | if (init == NULL) return LUA_OK; | 430 | if (init == NULL) return LUA_OK; |