diff options
author | Michael J. Spencer <bigcheesegs@gmail.com> | 2010-12-04 00:32:14 +0000 |
---|---|---|
committer | Michael J. Spencer <bigcheesegs@gmail.com> | 2010-12-04 00:32:14 +0000 |
commit | 4958466f9f93664780ab094ec8bd403e34c39ee3 (patch) | |
tree | 56ee591b4512b52c368226a897d58e54687b5b0e /lib/Support/Windows/PathV2.inc | |
parent | 01a87c413d9fcf03e717c4ebde8554e986f6f7cb (diff) |
Support/Windows/FileSystem: Fix MinGW warnings.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120868 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Support/Windows/PathV2.inc')
-rw-r--r-- | lib/Support/Windows/PathV2.inc | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/lib/Support/Windows/PathV2.inc b/lib/Support/Windows/PathV2.inc index dd7fefafc6..a84783f96a 100644 --- a/lib/Support/Windows/PathV2.inc +++ b/lib/Support/Windows/PathV2.inc @@ -70,7 +70,7 @@ namespace { error_code UTF16ToUTF8(const wchar_t *utf16, size_t utf16_len, SmallVectorImpl<char> &utf8) { // Get length. - int len = ::WideCharToMultiByte(CP_UTF8, NULL, + int len = ::WideCharToMultiByte(CP_UTF8, 0, utf16, utf16_len, utf8.begin(), 0, NULL, NULL); @@ -82,7 +82,7 @@ namespace { utf8.set_size(len); // Now do the actual conversion. - len = ::WideCharToMultiByte(CP_UTF8, NULL, + len = ::WideCharToMultiByte(CP_UTF8, 0, utf16, utf16_len, utf8.data(), utf8.size(), NULL, NULL); @@ -151,7 +151,7 @@ retry_cur_dir: // Find out how much space we need. Sadly, this function doesn't return the // size needed unless you tell it the result size is 0, which means you // _always_ have to call it twice. - len = ::WideCharToMultiByte(CP_UTF8, NULL, + len = ::WideCharToMultiByte(CP_UTF8, 0, cur_path.data(), cur_path.size(), result.data(), 0, NULL, NULL); @@ -162,7 +162,7 @@ retry_cur_dir: result.reserve(len); result.set_size(len); // Now do the actual conversion. - len = ::WideCharToMultiByte(CP_UTF8, NULL, + len = ::WideCharToMultiByte(CP_UTF8, 0, cur_path.data(), cur_path.size(), result.data(), result.size(), NULL, NULL); @@ -255,7 +255,7 @@ error_code create_symlink(const Twine &to, const Twine &from) { if (error_code ec = UTF8ToUTF16(f, wide_from)) return ec; if (error_code ec = UTF8ToUTF16(t, wide_to)) return ec; - if (!create_symbolic_link_api(wide_from.begin(), wide_to.begin(), NULL)) + if (!create_symbolic_link_api(wide_from.begin(), wide_to.begin(), 0)) return make_error_code(windows_error(::GetLastError())); return make_error_code(errc::success); @@ -460,7 +460,7 @@ error_code unique_file(const Twine &model, int &result_fd, NULL, NULL, PROV_RSA_FULL, - NULL); + 0); if (!success) return make_error_code(windows_error(::GetLastError())); |