aboutsummaryrefslogtreecommitdiff
path: root/toolsrc/src/commands_installation.cpp
diff options
context:
space:
mode:
authorAlexander Karatarakis <alkarata@microsoft.com>2016-12-15 18:24:06 -0800
committerAlexander Karatarakis <alkarata@microsoft.com>2016-12-15 18:24:06 -0800
commit15ca6919ad7d5dd86596603663845b3ea84d0d3b (patch)
tree0d4f514eeb6ab873fc3ac4bd747b11226a444a34 /toolsrc/src/commands_installation.cpp
parente4548a8cf46b20b8e89ab75ee9201e3b244484ba (diff)
downloadvcpkg-15ca6919ad7d5dd86596603663845b3ea84d0d3b.tar.gz
vcpkg-15ca6919ad7d5dd86596603663845b3ea84d0d3b.zip
Use Files::write_all_lines()
Diffstat (limited to 'toolsrc/src/commands_installation.cpp')
-rw-r--r--toolsrc/src/commands_installation.cpp7
1 files changed, 1 insertions, 6 deletions
diff --git a/toolsrc/src/commands_installation.cpp b/toolsrc/src/commands_installation.cpp
index e61a2dbfe..605343dfc 100644
--- a/toolsrc/src/commands_installation.cpp
+++ b/toolsrc/src/commands_installation.cpp
@@ -132,12 +132,7 @@ namespace vcpkg
System::println(System::color::error, "failed: %s: cannot handle file type", it->path().u8string());
}
- std::fstream listfile(paths.listfile_path(bpgh), std::ios_base::out | std::ios_base::binary | std::ios_base::trunc);
- for (const std::string& line : output)
- {
- listfile << line << "\n";
- }
- listfile.close();
+ Files::write_all_lines(paths.listfile_path(bpgh), output);
}
static void remove_first_n_chars(std::vector<std::string>* strings, const size_t n)