diff options
author | Peter Melnichenko <mpeterval@gmail.com> | 2018-03-15 22:10:09 +0300 |
---|---|---|
committer | Hisham Muhammad <hisham@gobolinux.org> | 2020-04-20 18:50:38 -0300 |
commit | 04ba8d686ab0e6ee7daaea092800ea44fcef40b5 (patch) | |
tree | faa3a9961784c618fd7b388e5795568546392f78 | |
parent | 04bdaf9a1eb1406f83321e98daf08b0f06a8401b (diff) | |
download | luafilesystem-04ba8d686ab0e6ee7daaea092800ea44fcef40b5.tar.gz luafilesystem-04ba8d686ab0e6ee7daaea092800ea44fcef40b5.tar.bz2 luafilesystem-04ba8d686ab0e6ee7daaea092800ea44fcef40b5.zip |
Support Lua 5.4
-rw-r--r-- | src/lfs.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -77,7 +77,7 @@ | |||
77 | #define LFS_VERSION "1.7.0" | 77 | #define LFS_VERSION "1.7.0" |
78 | #define LFS_LIBNAME "lfs" | 78 | #define LFS_LIBNAME "lfs" |
79 | 79 | ||
80 | #if LUA_VERSION_NUM >= 503 /* Lua 5.3 */ | 80 | #if LUA_VERSION_NUM >= 503 /* Lua 5.3+ */ |
81 | 81 | ||
82 | #ifndef luaL_optlong | 82 | #ifndef luaL_optlong |
83 | #define luaL_optlong luaL_optinteger | 83 | #define luaL_optlong luaL_optinteger |
@@ -226,7 +226,7 @@ static FILE *check_file (lua_State *L, int idx, const char *funcname) { | |||
226 | return 0; | 226 | return 0; |
227 | } else | 227 | } else |
228 | return *fh; | 228 | return *fh; |
229 | #elif LUA_VERSION_NUM >= 502 && LUA_VERSION_NUM <= 503 | 229 | #elif LUA_VERSION_NUM >= 502 && LUA_VERSION_NUM <= 504 |
230 | luaL_Stream *fh = (luaL_Stream *)luaL_checkudata (L, idx, "FILE*"); | 230 | luaL_Stream *fh = (luaL_Stream *)luaL_checkudata (L, idx, "FILE*"); |
231 | if (fh->closef == 0 || fh->f == NULL) { | 231 | if (fh->closef == 0 || fh->f == NULL) { |
232 | luaL_error (L, "%s: closed file", funcname); | 232 | luaL_error (L, "%s: closed file", funcname); |