aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorReuben Thomas <rrt@sc3d.org>2011-06-09 14:01:37 +0100
committerReuben Thomas <rrt@sc3d.org>2011-06-09 19:53:41 +0100
commit530c9140c7628f7062e2caff73c94e547ea0c45f (patch)
treeef6cb15541530ea6cea22999769132f43c80c70e /src
parentd292b3243f90ba21450c0599b42aa89e999524ee (diff)
downloadluafilesystem-530c9140c7628f7062e2caff73c94e547ea0c45f.tar.gz
luafilesystem-530c9140c7628f7062e2caff73c94e547ea0c45f.tar.bz2
luafilesystem-530c9140c7628f7062e2caff73c94e547ea0c45f.zip
Add trivial link_info support on Windows (using STAT_FUNC).
Diffstat (limited to 'src')
-rw-r--r--src/lfs.c9
1 files changed, 1 insertions, 8 deletions
diff --git a/src/lfs.c b/src/lfs.c
index 8e94d4f..63d2dbd 100644
--- a/src/lfs.c
+++ b/src/lfs.c
@@ -96,6 +96,7 @@ typedef struct dir_data {
96 #define STAT_STRUCT struct _stati64 96 #define STAT_STRUCT struct _stati64
97 #endif 97 #endif
98#define STAT_FUNC _stati64 98#define STAT_FUNC _stati64
99#define LSTAT_FUNC STAT_FUNC
99#else 100#else
100#define _O_TEXT 0 101#define _O_TEXT 0
101#define _O_BINARY 0 102#define _O_BINARY 0
@@ -743,17 +744,9 @@ static int file_info (lua_State *L) {
743/* 744/*
744** Get symbolic link information using lstat. 745** Get symbolic link information using lstat.
745*/ 746*/
746#ifndef _WIN32
747static int link_info (lua_State *L) { 747static int link_info (lua_State *L) {
748 return _file_info_ (L, LSTAT_FUNC); 748 return _file_info_ (L, LSTAT_FUNC);
749} 749}
750#else
751static int link_info (lua_State *L) {
752 lua_pushboolean(L, 0);
753 lua_pushliteral(L, "symlinkattributes not supported on this platform");
754 return 2;
755}
756#endif
757 750
758 751
759/* 752/*