-----------------------------------------------------------------------------
| 853 | |
| 854 | //----------------------------------------------------------------------------- |
| 855 | bool Platform::getFileTimes(const char *filePath, FileTime *createTime, FileTime *modifyTime) |
| 856 | { |
| 857 | char pathName[MaxPath]; |
| 858 | |
| 859 | // if it starts with cwd, we need to strip that off so that we can look for |
| 860 | // the file in the pref dir |
| 861 | char cwd[MaxPath]; |
| 862 | getcwd(cwd, MaxPath); |
| 863 | if (dStrstr(filePath, cwd) == filePath) |
| 864 | filePath = filePath + dStrlen(cwd) + 1; |
| 865 | |
| 866 | // if its relative, first look in the pref dir |
| 867 | if (filePath[0] != '/' && filePath[0] != '\\') |
| 868 | { |
| 869 | MungePath(pathName, MaxPath, filePath, GetPrefDir()); |
| 870 | if (GetFileTimes(pathName, createTime, modifyTime)) |
| 871 | return true; |
| 872 | } |
| 873 | |
| 874 | // here if the path is absolute or not in the pref dir |
| 875 | MungePath(pathName, MaxPath, filePath, cwd); |
| 876 | return GetFileTimes(pathName, createTime, modifyTime); |
| 877 | } |
| 878 | |
| 879 | //----------------------------------------------------------------------------- |
| 880 | bool Platform::createPath(const char *file) |
nothing calls this directly
no test coverage detected