- backend update from GZDoom.

This commit is contained in:
Christoph Oelckers 2021-02-12 14:44:54 +01:00
parent 5b6aa372ea
commit c96e04e6c9
28 changed files with 352 additions and 119 deletions

View file

@ -165,6 +165,24 @@ bool FileExists (const char *filename)
return res && !isdir;
}
//==========================================================================
//
// FileReadable
//
// Returns true if the file can be read.
//
//==========================================================================
bool FileReadable(const char *filename)
{
#ifndef _WIN32
return access (filename, R_OK) == 0;
#else
auto wstr = WideString(filename);
return _waccess (wstr.c_str(), 4) == 0;
#endif
}
//==========================================================================
//
// DirExists