-----------------------------------------------------------------------------
| 830 | |
| 831 | //----------------------------------------------------------------------------- |
| 832 | static bool GetFileTimes(const char *filePath, FileTime *createTime, FileTime *modifyTime) |
| 833 | { |
| 834 | struct stat fStat; |
| 835 | |
| 836 | if (stat(filePath, &fStat) == -1) |
| 837 | return false; |
| 838 | |
| 839 | if(createTime) |
| 840 | { |
| 841 | // no where does SysV/BSD UNIX keep a record of a file's |
| 842 | // creation time. instead of creation time I'll just use |
| 843 | // changed time for now. |
| 844 | *createTime = fStat.st_ctime; |
| 845 | } |
| 846 | if(modifyTime) |
| 847 | { |
| 848 | *modifyTime = fStat.st_mtime; |
| 849 | } |
| 850 | |
| 851 | return true; |
| 852 | } |
| 853 | |
| 854 | //----------------------------------------------------------------------------- |
| 855 | bool Platform::getFileTimes(const char *filePath, FileTime *createTime, FileTime *modifyTime) |