diff --git a/src/os.cpp b/src/os.cpp index 715786735888ad6d15506513bf431b7907cda818..8eb6b346541c2fe2b8105418c994d055e40facd3 100644 --- a/src/os.cpp +++ b/src/os.cpp @@ -1838,7 +1838,7 @@ Error os_file_open_r(Buf *full_path, OsFile *out_file, OsTimeStamp *mtime) { if (mtime != nullptr) { FILETIME last_write_time; - if (!GetFileTime(file, nullptr, nullptr, &last_write_time)) { + if (!GetFileTime(result, nullptr, nullptr, &last_write_time)) { CloseHandle(result); return ErrorUnexpected; }