Add trivial link_info support on Windows (using STAT_FUNC).

This commit is contained in:
Reuben Thomas
2011-06-09 14:01:37 +01:00
parent d292b3243f
commit 530c9140c7
3 changed files with 8 additions and 17 deletions

View File

@@ -96,6 +96,7 @@ typedef struct dir_data {
#define STAT_STRUCT struct _stati64
#endif
#define STAT_FUNC _stati64
#define LSTAT_FUNC STAT_FUNC
#else
#define _O_TEXT 0
#define _O_BINARY 0
@@ -743,17 +744,9 @@ static int file_info (lua_State *L) {
/*
** Get symbolic link information using lstat.
*/
#ifndef _WIN32
static int link_info (lua_State *L) {
return _file_info_ (L, LSTAT_FUNC);
}
#else
static int link_info (lua_State *L) {
lua_pushboolean(L, 0);
lua_pushliteral(L, "symlinkattributes not supported on this platform");
return 2;
}
#endif
/*