From: brian Date: Wed, 14 May 2003 17:09:44 +0000 (+0000) Subject: fixed bug in MultipleSelection Class. X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=364c991a65c9faa86e73d505c267da4263179f3e;p=dealii-svn.git fixed bug in MultipleSelection Class. git-svn-id: https://svn.dealii.org/trunk@7646 0785d39b-7218-0410-832d-ea1e28bc413d --- diff --git a/deal.II/base/source/parameter_handler.cc b/deal.II/base/source/parameter_handler.cc index 3ae2f1b6fe..22f3f6a1e3 100644 --- a/deal.II/base/source/parameter_handler.cc +++ b/deal.II/base/source/parameter_handler.cc @@ -321,9 +321,9 @@ namespace Patterns // first split the input list while (tmp.length() != 0) { - std::string name; + std::string name; name = tmp; - + if (name.find(",") != std::string::npos) { name.erase (name.find(","), std::string::npos); @@ -335,6 +335,7 @@ namespace Patterns while ((name.length() != 0) && (name[0] == ' ')) name.erase (0,1); + while (name[name.length()-1] == ' ') name.erase (name.length()-1, 1); @@ -421,7 +422,7 @@ namespace Patterns if (name.find(",") != std::string::npos) { name.erase (name.find(","), std::string::npos); - tmp.erase (0, test_string_list.find(",")+1); + tmp.erase (0, tmp.find(",")+1); } else tmp = "";