aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/ecore_file/ecore_file.c
diff options
context:
space:
mode:
authorVincent Torri <vincent.torri@gmail.com>2018-01-27 15:17:17 +0100
committerJean-Philippe Andre <jp.andre@samsung.com>2018-01-30 16:52:24 +0900
commitef0f0a50b2912f442f14dc2ba3c071b7122faf6e (patch)
tree40b8f9b970f72167db45f0f7aed7c33a7f706a7d /src/lib/ecore_file/ecore_file.c
parentWindows: remove symlink() usage in edje_decc and evil binaries (diff)
downloadefl-ef0f0a50b2912f442f14dc2ba3c071b7122faf6e.tar.gz
Ecore_File: remove symlinks support on Windows (library and test)
Diffstat (limited to '')
-rw-r--r--src/lib/ecore_file/ecore_file.c18
1 files changed, 11 insertions, 7 deletions
diff --git a/src/lib/ecore_file/ecore_file.c b/src/lib/ecore_file/ecore_file.c
index 15d96edb6e..89b6f2b373 100644
--- a/src/lib/ecore_file/ecore_file.c
+++ b/src/lib/ecore_file/ecore_file.c
@@ -320,11 +320,6 @@ ecore_file_recursive_rm(const char *dir)
Eina_Bool is_dir;
#ifdef _WIN32
- char buf[PATH_MAX];
-
- if (readlink(dir, buf, sizeof(buf) - 1) > 0)
- return ecore_file_unlink(dir);
-
if (!_ecore_file_stat(dir, NULL, NULL, NULL, &is_dir, NULL))
return EINA_FALSE;
#else
@@ -545,9 +540,13 @@ FAIL:
EAPI Eina_Bool
ecore_file_symlink(const char *src, const char *dest)
{
- if (!symlink(src, dest)) return EINA_TRUE;
-
+#ifndef _WIN32
+ return !symlink(src, dest);
+#else
return EINA_FALSE;
+ (void)src;
+ (void)dest;
+#endif
}
EAPI char *
@@ -630,12 +629,17 @@ ecore_file_can_exec(const char *file)
EAPI char *
ecore_file_readlink(const char *link)
{
+#ifndef _WIN32
char buf[PATH_MAX];
int count;
if ((count = readlink(link, buf, sizeof(buf) - 1)) < 0) return NULL;
buf[count] = 0;
return strdup(buf);
+#else
+ return NULL;
+ (void)link;
+#endif
}
EAPI Eina_List *