mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2024-11-26 06:10:56 +00:00
Rename Sys_FileTime to Sys_FileExists.
The function never did anything but check the readability of the file.
This commit is contained in:
parent
9047c3e4ad
commit
4e7e7c3ab0
4 changed files with 7 additions and 7 deletions
|
@ -58,7 +58,7 @@ typedef struct date_s {
|
|||
char str[128];
|
||||
} date_t;
|
||||
|
||||
int Sys_FileTime (const char *path);
|
||||
int Sys_FileExists (const char *path);
|
||||
int Sys_mkdir (const char *path);
|
||||
|
||||
typedef void (*sys_printf_t) (const char *fmt, va_list args);
|
||||
|
|
|
@ -847,7 +847,7 @@ open_file (searchpath_t *search, const char *filename, QFile **gzfile,
|
|||
dstring_clearstr (foundname);
|
||||
dstring_appendstr (foundname, filename);
|
||||
}
|
||||
if (Sys_FileTime (netpath->str) == -1) {
|
||||
if (Sys_FileExists (netpath->str) == -1) {
|
||||
dstring_delete (netpath);
|
||||
return -1;
|
||||
}
|
||||
|
@ -1399,7 +1399,7 @@ QFS_NextFilename (dstring_t *filename, const char *prefix, const char *ext)
|
|||
|
||||
if (qfs_expand_userpath (full_path, filename->str) == -1)
|
||||
break;
|
||||
if (Sys_FileTime (full_path->str) == -1) {
|
||||
if (Sys_FileExists (full_path->str) == -1) {
|
||||
// file doesn't exist, so we can use this name
|
||||
ret = 1;
|
||||
break;
|
||||
|
|
|
@ -185,7 +185,7 @@ Sys_mkdir (const char *path)
|
|||
}
|
||||
|
||||
VISIBLE int
|
||||
Sys_FileTime (const char *path)
|
||||
Sys_FileExists (const char *path)
|
||||
{
|
||||
#ifdef HAVE_ACCESS
|
||||
if (access (path, R_OK) == 0)
|
||||
|
|
|
@ -578,7 +578,7 @@ Cmd_Base (void)
|
|||
ExpandPath/*AndArchive*/ (file1);
|
||||
|
||||
sprintf (file1, "%s/%s.tri", cddir, scr.token->str);
|
||||
time1 = Sys_FileTime (file1);
|
||||
time1 = Sys_FileExists (file1);
|
||||
if (time1 == -1)
|
||||
Sys_Error ("%s doesn't exist", file1);
|
||||
|
||||
|
@ -633,7 +633,7 @@ Cmd_Skin (void)
|
|||
ExpandPath/*AndArchive*/ (file1);
|
||||
|
||||
sprintf (file1, "%s/%s.lbm", cddir, scr.token->str);
|
||||
time1 = Sys_FileTime (file1);
|
||||
time1 = Sys_FileExists (file1);
|
||||
if (time1 == -1)
|
||||
Sys_Error ("%s not found", file1);
|
||||
|
||||
|
@ -683,7 +683,7 @@ GrabFrame (char *frame, int isgroup)
|
|||
ExpandPath/*AndArchive*/ (file1);
|
||||
|
||||
sprintf (file1, "%s/%s.tri", cddir, frame);
|
||||
time1 = Sys_FileTime (file1);
|
||||
time1 = Sys_FileExists (file1);
|
||||
if (time1 == -1)
|
||||
Sys_Error ("%s does not exist", file1);
|
||||
|
||||
|
|
Loading…
Reference in a new issue