added file delete

This commit is contained in:
jsorg71 2005-11-05 23:51:10 +00:00
parent 489fddf5f2
commit 97b1407d91
2 changed files with 14 additions and 0 deletions

View File

@ -584,6 +584,18 @@ g_file_exist(char* filename)
#endif
}
/*****************************************************************************/
/* 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)

View File

@ -102,6 +102,8 @@ g_set_current_dir(char* dirname);
int
g_file_exist(char* filename);
int
g_file_delete(char* filename);
int
g_strlen(char* text);
char*
g_strcpy(char* dest, char* src);