diff options
author | Scott Graham <scottmg@chromium.org> | 2014-06-19 18:22:44 (GMT) |
---|---|---|
committer | Scott Graham <scottmg@chromium.org> | 2014-06-19 18:22:44 (GMT) |
commit | 78d6bb9b6794c01308dba313f75e205d43f95e23 (patch) | |
tree | 4abe132b88ab20a809c3360e38570c7cc838e99c | |
parent | f8776ed9ee1134b176ea23dd7ab96f2eeca33c04 (diff) | |
download | Ninja-78d6bb9b6794c01308dba313f75e205d43f95e23.zip Ninja-78d6bb9b6794c01308dba313f75e205d43f95e23.tar.gz Ninja-78d6bb9b6794c01308dba313f75e205d43f95e23.tar.bz2 |
use local definition of FindExInfoBasic for earlier sdks
-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); |