diff options
-rw-r--r-- | hscript/script_e.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/hscript/script_e.cc b/hscript/script_e.cc index 2ad1a98..3cdc78f 100644 --- a/hscript/script_e.cc +++ b/hscript/script_e.cc @@ -347,14 +347,14 @@ bool Script::execute() const { case NetConfigType::Netifrc: { const std::string variable(varfile.path().filename().string()); conf << variable << "=\""; - if(contents.rdbuf()->in_avail()) conf << contents.rdbuf(); + contents >> conf.rdbuf(); conf << "\"" << std::endl; break; } case NetConfigType::ENI: { const std::string iface(varfile.path().filename().string()); conf << "auto " << iface << std::endl; - if(contents.rdbuf()->in_avail()) conf << contents.rdbuf(); + contents >> conf.rdbuf(); conf << std::endl; break; } |