diff options
author | Jose Fonseca <jfonseca@vmware.com> | 2015-06-24 11:29:01 +0100 |
---|---|---|
committer | Jose Fonseca <jfonseca@vmware.com> | 2015-06-24 11:34:05 +0100 |
commit | 8b0807fc98700fdaf69ed880eab416e43194f219 (patch) | |
tree | 93bdb1a88a30895be566867dd9c6ccee51bb024a /cli | |
parent | 5ee868140e0ee87fcc3aa4da48aea0d14bb0bcfb (diff) |
cli/sed: Open file in text mode.
There might be situations where we want the opposite. But at least for
now this enables to run unit tests on Windows.
Diffstat (limited to 'cli')
-rw-r--r-- | cli/cli_sed.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/cli/cli_sed.cpp b/cli/cli_sed.cpp index b651ebc9..1ad035b9 100644 --- a/cli/cli_sed.cpp +++ b/cli/cli_sed.cpp @@ -272,7 +272,7 @@ parseSubstOpt(Replacements &replacements, const char *opt) std::string fname = str->substr(file_subst.length()); fname[fname.length()-1] = 0; - FILE *f = fopen(fname.c_str(), "r"); + FILE *f = fopen(fname.c_str(), "rt"); if (!f) { std::cerr << "error: cannot open file " << fname << "\n"; return false; |