From a5be9eb1faa85fd314105544959f1a378e901de5 Mon Sep 17 00:00:00 2001 From: Wintermate Date: Tue, 22 Oct 2013 14:32:48 +0200 Subject: [PATCH 1/1] Level-Konverter: Leerzeichen am Ende von Optionszeilen trimmen. --- mock/tools/level-converter.cc | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/mock/tools/level-converter.cc b/mock/tools/level-converter.cc index eccd3e0..88e9315 100644 --- a/mock/tools/level-converter.cc +++ b/mock/tools/level-converter.cc @@ -6,6 +6,7 @@ extern "C" { } #include +#include #include #include @@ -77,7 +78,7 @@ namespace jnrcpp { std::string name; while(std::getline(in, name)) { - if(name != "") { + if(boost::trim_copy(name) != "") { names.push_back(name); } } @@ -119,7 +120,7 @@ namespace jnrcpp { } else { throw std::invalid_argument("Unkown type: " + line); } - } else if(line != "") { + } else if(boost::trim_right_copy(line) != "") { char c; std::string tok; std::istringstream parser(line); -- 2.20.1