Skip to content
Snippets Groups Projects
Commit 0414f331 authored by Nicolas Pope's avatar Nicolas Pope
Browse files

Merge branch 'bug/342/windowsftl' into 'master'

Resolves #342 windows ftl playback

Closes #342

See merge request nicolas.pope/ftl!288
parents 8c315324 401d6085
Branches
Tags
1 merge request!288Resolves #342 windows ftl playback
Pipeline #22885 passed
...@@ -270,7 +270,7 @@ bool File::_open() { ...@@ -270,7 +270,7 @@ bool File::_open() {
istream_->seekg(0); istream_->seekg(0);
} else { } else {
if (!istream_) istream_ = new std::ifstream; if (!istream_) istream_ = new std::ifstream;
istream_->open(*get<std::string>("filename")); istream_->open(*get<std::string>("filename"), std::ifstream::in | std::ifstream::binary);
if (!istream_->good()) { if (!istream_->good()) {
LOG(ERROR) << "Could not open file: " << *get<std::string>("filename"); LOG(ERROR) << "Could not open file: " << *get<std::string>("filename");
...@@ -314,7 +314,7 @@ bool File::begin(bool dorun) { ...@@ -314,7 +314,7 @@ bool File::begin(bool dorun) {
if (dorun) run(); if (dorun) run();
} else if (mode_ == Mode::Write) { } else if (mode_ == Mode::Write) {
if (!ostream_) ostream_ = new std::ofstream; if (!ostream_) ostream_ = new std::ofstream;
ostream_->open(*get<std::string>("filename")); ostream_->open(*get<std::string>("filename"), std::ifstream::out | std::ifstream::binary);
if (!ostream_->good()) { if (!ostream_->good()) {
LOG(ERROR) << "Could not open file: " << *get<std::string>("filename"); LOG(ERROR) << "Could not open file: " << *get<std::string>("filename");
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment