aboutsummaryrefslogtreecommitdiffstats
path: root/legacy/ecore/src/lib/ecore_file/ecore_file.c
diff options
context:
space:
mode:
authorVincent Torri <vincent.torri@gmail.com>2009-12-19 19:09:37 +0000
committerVincent Torri <vincent.torri@gmail.com>2009-12-19 19:09:37 +0000
commit5cffd43943bab95751b84dc5123c1f90695c7442 (patch)
tree4f8e46478e5c6befcc521857dd17292b8b9f0631 /legacy/ecore/src/lib/ecore_file/ecore_file.c
parent * Makefile.am: (diff)
downloadefl-5cffd43943bab95751b84dc5123c1f90695c7442.tar.gz
add a wrapper around remove()
SVN revision: 44578
Diffstat (limited to '')
-rw-r--r--legacy/ecore/src/lib/ecore_file/ecore_file.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/legacy/ecore/src/lib/ecore_file/ecore_file.c b/legacy/ecore/src/lib/ecore_file/ecore_file.c
index 064016ae80..318d6fff19 100644
--- a/legacy/ecore/src/lib/ecore_file/ecore_file.c
+++ b/legacy/ecore/src/lib/ecore_file/ecore_file.c
@@ -296,6 +296,18 @@ ecore_file_unlink(const char *file)
}
/**
+ * Remove the given file or directory
+ * @param file The name of the file or directory to delete
+ * @return 1 on success, 0 on failure
+ */
+EAPI int
+ecore_file_remove(const char *file)
+{
+ if (remove(file) < 0) return 0;
+ return 1;
+}
+
+/**
* Delete a directory and all its contents
* @param dir The name of the directory to delete
* @return 1 on success, 0 on failure