mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-02-02 20:34:41 +00:00
(svn r15664) -Fix [FS#2716]: as always windows needs special handling when strings are involved
This commit is contained in:
parent
d6f2a65323
commit
f45e3b3068
@ -230,8 +230,13 @@ bool FiosFileScanner::AddFile(const char *filename, size_t basepath_length)
|
||||
}
|
||||
|
||||
FiosItem *fios = _fios_items.Append();
|
||||
#ifdef WIN32
|
||||
struct _stat sb;
|
||||
if (_tstat(OTTD2FS(filename), &sb) == 0) {
|
||||
#else
|
||||
struct stat sb;
|
||||
if (stat(filename, &sb) == 0) {
|
||||
#endif
|
||||
fios->mtime = sb.st_mtime;
|
||||
} else {
|
||||
fios->mtime = 0;
|
||||
|
Loading…
Reference in New Issue
Block a user