summaryrefslogtreecommitdiffstats
path: root/common/os_calls.c
diff options
context:
space:
mode:
authorjsorg71 <jsorg71>2005-11-05 23:51:10 +0000
committerjsorg71 <jsorg71>2005-11-05 23:51:10 +0000
commit97b1407d916c4da6b25983e901cef231659034a5 (patch)
tree2f37300a702723681fcc1eb8cac8b5305844b254 /common/os_calls.c
parent489fddf5f2dd68b94749fe4cfd43c35269d465be (diff)
downloadxrdp-proprietary-97b1407d916c4da6b25983e901cef231659034a5.tar.gz
xrdp-proprietary-97b1407d916c4da6b25983e901cef231659034a5.zip
added file delete
Diffstat (limited to 'common/os_calls.c')
-rw-r--r--common/os_calls.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/common/os_calls.c b/common/os_calls.c
index 4d78887c..366a4832 100644
--- a/common/os_calls.c
+++ b/common/os_calls.c
@@ -585,6 +585,18 @@ g_file_exist(char* filename)
}
/*****************************************************************************/
+/* returns non zero if the file was deleted */
+int
+g_file_delete(char* filename)
+{
+#if defined(_WIN32)
+ return DeleteFile(filename);
+#else
+ return unlink(filename) != -1;
+#endif
+}
+
+/*****************************************************************************/
int
g_strlen(char* text)
{