summaryrefslogtreecommitdiffstats
path: root/src/disk_interface.cc
diff options
context:
space:
mode:
authorNico Weber <nicolasweber@gmx.de>2014-06-19 19:21:33 (GMT)
committerNico Weber <nicolasweber@gmx.de>2014-06-19 19:21:33 (GMT)
commitfcca327e0c66dfec49af28f09f94b94ac49c5cb4 (patch)
tree4abe132b88ab20a809c3360e38570c7cc838e99c /src/disk_interface.cc
parentf8776ed9ee1134b176ea23dd7ab96f2eeca33c04 (diff)
parent78d6bb9b6794c01308dba313f75e205d43f95e23 (diff)
downloadNinja-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.cc5
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);