diff options
author | Nico Weber <nicolasweber@gmx.de> | 2014-06-19 19:21:33 (GMT) |
---|---|---|
committer | Nico Weber <nicolasweber@gmx.de> | 2014-06-19 19:21:33 (GMT) |
commit | fcca327e0c66dfec49af28f09f94b94ac49c5cb4 (patch) | |
tree | 4abe132b88ab20a809c3360e38570c7cc838e99c /src/disk_interface.cc | |
parent | f8776ed9ee1134b176ea23dd7ab96f2eeca33c04 (diff) | |
parent | 78d6bb9b6794c01308dba313f75e205d43f95e23 (diff) | |
download | Ninja-fcca327e0c66dfec49af28f09f94b94ac49c5cb4.zip Ninja-fcca327e0c66dfec49af28f09f94b94ac49c5cb4.tar.gz Ninja-fcca327e0c66dfec49af28f09f94b94ac49c5cb4.tar.bz2 |
Merge pull request #783 from sgraham/findexinfobasic
use local definition of FindExInfoBasic for earlier sdks
Diffstat (limited to 'src/disk_interface.cc')
-rw-r--r-- | src/disk_interface.cc | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/disk_interface.cc b/src/disk_interface.cc index dfea469..c329aa3 100644 --- a/src/disk_interface.cc +++ b/src/disk_interface.cc @@ -97,8 +97,11 @@ bool StatAllFilesInDir(const string& dir, map<string, TimeStamp>* stamps, bool quiet) { // FindExInfoBasic is 30% faster than FindExInfoStandard. static bool can_use_basic_info = IsWindows7OrLater(); + // This is not in earlier SDKs. + const FINDEX_INFO_LEVELS kFindExInfoBasic = + static_cast<FINDEX_INFO_LEVELS>(1); FINDEX_INFO_LEVELS level = - can_use_basic_info ? FindExInfoBasic : FindExInfoStandard; + can_use_basic_info ? kFindExInfoBasic : FindExInfoStandard; WIN32_FIND_DATAA ffd; HANDLE find_handle = FindFirstFileExA((dir + "\\*").c_str(), level, &ffd, FindExSearchNameMatch, NULL, 0); |