mirror of
https://github.com/ToruNiina/toml11.git
synced 2024-12-24 18:21:04 +00:00
open file with binary mode
This commit is contained in:
parent
e2d75bf1a9
commit
80adda8184
@ -1071,7 +1071,7 @@ toml::Table parse(std::basic_istream<toml::character, traits>& is)
|
|||||||
|
|
||||||
toml::Table parse(const std::string& filename)
|
toml::Table parse(const std::string& filename)
|
||||||
{
|
{
|
||||||
std::ifstream ifs(filename);
|
std::ifstream ifs(filename, std::ios_base::in | std::ios_base::binary);
|
||||||
if(!ifs.good()) throw std::runtime_error("file open error: " + filename);
|
if(!ifs.good()) throw std::runtime_error("file open error: " + filename);
|
||||||
return parse(ifs);
|
return parse(ifs);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user