diff options
author | Zachary Turner <zturner@google.com> | 2017-03-20 23:55:20 +0000 |
---|---|---|
committer | Zachary Turner <zturner@google.com> | 2017-03-20 23:55:20 +0000 |
commit | 5821a3bf366a5d401930c2632fdb7acfe39046b2 (patch) | |
tree | a3257244016e1680cd9360c641909b85a1a31edd /llvm/lib/Support/Windows/Path.inc | |
parent | 076a2599388d8a9efa90207291310c16b9322b1a (diff) | |
download | bcm5719-llvm-5821a3bf366a5d401930c2632fdb7acfe39046b2.tar.gz bcm5719-llvm-5821a3bf366a5d401930c2632fdb7acfe39046b2.zip |
[Support] Fill the file_status struct with link count.
Differential Revision: https://reviews.llvm.org/D31110
llvm-svn: 298326
Diffstat (limited to 'llvm/lib/Support/Windows/Path.inc')
-rw-r--r-- | llvm/lib/Support/Windows/Path.inc | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/llvm/lib/Support/Windows/Path.inc b/llvm/lib/Support/Windows/Path.inc index 97682c11839..b00d3905f65 100644 --- a/llvm/lib/Support/Windows/Path.inc +++ b/llvm/lib/Support/Windows/Path.inc @@ -179,6 +179,10 @@ TimePoint<> file_status::getLastModificationTime() const { return toTimePoint(Time); } +uint32_t file_status::getLinkCount() const { + return NumLinks; +} + std::error_code current_path(SmallVectorImpl<char> &result) { SmallVector<wchar_t, MAX_PATH> cur_path; DWORD len = MAX_PATH; @@ -534,7 +538,8 @@ static std::error_code getStatus(HANDLE FileHandle, file_status &Result) { ? (all_read | all_exe) : all_all; Result = file_status( - Type, Permissions, Info.ftLastAccessTime.dwHighDateTime, + Type, Permissions, Info.nNumberOfLinks, + Info.ftLastAccessTime.dwHighDateTime, Info.ftLastAccessTime.dwLowDateTime, Info.ftLastWriteTime.dwHighDateTime, Info.ftLastWriteTime.dwLowDateTime, Info.dwVolumeSerialNumber, Info.nFileSizeHigh, Info.nFileSizeLow, |