mirror of
https://github.com/loot/libloot.git
synced 2026-07-27 14:16:01 -07:00
Update main.cpp
Switched file streams to those that can open non-ANSI file paths (the header file "streams.h" has not yet been committed).
This commit is contained in:
+4
-3
@@ -32,6 +32,7 @@
|
||||
#include "../backend/helpers.h"
|
||||
#include "../backend/generators.h"
|
||||
#include "../backend/network.h"
|
||||
#include "../backend/streams.h"
|
||||
|
||||
#include <ostream>
|
||||
#include <algorithm>
|
||||
@@ -376,7 +377,7 @@ void Launcher::OnClose(wxCloseEvent& event) {
|
||||
yout.SetIndent(2);
|
||||
yout << _settings;
|
||||
|
||||
ofstream out(boss::g_path_settings.string().c_str());
|
||||
boss::ofstream out(boss::g_path_settings.string().c_str());
|
||||
out << yout.c_str();
|
||||
out.close();
|
||||
|
||||
@@ -652,7 +653,7 @@ void Launcher::OnSortPlugins(wxCommandEvent& event) {
|
||||
<< YAML::Key << "plugins" << YAML::Value << ulist_plugins
|
||||
<< YAML::EndMap;
|
||||
|
||||
ofstream uout(_game.UserlistPath().string().c_str());
|
||||
boss::ofstream uout(_game.UserlistPath().string().c_str());
|
||||
uout << yout.c_str();
|
||||
uout.close();
|
||||
|
||||
@@ -686,7 +687,7 @@ void Launcher::OnSortPlugins(wxCommandEvent& event) {
|
||||
if (fs::exists(_game.ReportPath().string())) {
|
||||
BOOST_LOG_TRIVIAL(debug) << "Reading the previous report's details section.";
|
||||
//Read the whole file in.
|
||||
ifstream in(_game.ReportPath().string().c_str(), ios::binary);
|
||||
boss::ifstream in(_game.ReportPath().string().c_str(), ios::binary);
|
||||
in.seekg(0, std::ios::end);
|
||||
oldDetails.resize(in.tellg());
|
||||
in.seekg(0, std::ios::beg);
|
||||
|
||||
Reference in New Issue
Block a user