aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVincent Torri <vincent.torri@gmail.com>2018-01-27 15:18:59 +0100
committerJean-Philippe Andre <jp.andre@samsung.com>2018-01-30 16:52:24 +0900
commit78af66ffb408021275e15364cf3b1039f8d2d59a (patch)
tree232e0d5de3bfce12a000b7f50fa6d4df5ff33d09
parentEcore_File: remove symlinks support on Windows (library and test) (diff)
downloadefl-78af66ffb408021275e15364cf3b1039f8d2d59a.tar.gz
Eina: ignore EINA_FILE_LNK on Windows
-rw-r--r--src/lib/eina/eina_file.h2
-rw-r--r--src/lib/eina/eina_file_win32.c8
2 files changed, 4 insertions, 6 deletions
diff --git a/src/lib/eina/eina_file.h b/src/lib/eina/eina_file.h
index bccadeb734..a9743e91c1 100644
--- a/src/lib/eina/eina_file.h
+++ b/src/lib/eina/eina_file.h
@@ -123,7 +123,7 @@ typedef enum {
EINA_FILE_DIR, /**< Directory type */
EINA_FILE_BLK, /**< Block device type (unused on Windows) */
EINA_FILE_REG, /**< Regular file type */
- EINA_FILE_LNK, /**< Symbolic link type */
+ EINA_FILE_LNK, /**< Symbolic link type (unused on Windows) */
EINA_FILE_SOCK, /**< UNIX domain socket type (unused on Windows) */
EINA_FILE_WHT /**< Whiteout file type (unused on Windows) */
} Eina_File_Type;
diff --git a/src/lib/eina/eina_file_win32.c b/src/lib/eina/eina_file_win32.c
index 4cb0a22ac9..537723e01b 100644
--- a/src/lib/eina/eina_file_win32.c
+++ b/src/lib/eina/eina_file_win32.c
@@ -330,14 +330,13 @@ _eina_file_win32_direct_ls_iterator_next(Eina_File_Direct_Iterator *it, void **d
if (attr & FILE_ATTRIBUTE_DIRECTORY)
it->info.type = EINA_FILE_DIR;
- else if (attr & FILE_ATTRIBUTE_REPARSE_POINT)
- it->info.type = EINA_FILE_LNK;
else if (attr & (FILE_ATTRIBUTE_ARCHIVE |
FILE_ATTRIBUTE_COMPRESSED |
FILE_ATTRIBUTE_HIDDEN |
FILE_ATTRIBUTE_NORMAL |
FILE_ATTRIBUTE_SPARSE_FILE |
- FILE_ATTRIBUTE_TEMPORARY))
+ FILE_ATTRIBUTE_TEMPORARY |
+ FILE_ATTRIBUTE_REPARSE_POINT))
it->info.type = EINA_FILE_REG;
else
it->info.type = EINA_FILE_UNKNOWN;
@@ -1061,8 +1060,7 @@ eina_file_statat(void *container EINA_UNUSED, Eina_File_Direct_Info *info, Eina_
if (stat64(info->path, &buf))
{
- if (info->type != EINA_FILE_LNK)
- info->type = EINA_FILE_UNKNOWN;
+ info->type = EINA_FILE_UNKNOWN;
return -1;
}