X-Git-Url: https://git.librecmc.org/?a=blobdiff_plain;f=src%2Fsettings.h;h=4bc22eaa1e08f47682108872b272a7790dc246d4;hb=347216d654e6f284119d9473db03e3393002b286;hp=e8f376938676ecee172f247e189325098ac47c06;hpb=43a28f04fa3ddf4b612f58c25a896293a01567e3;p=oweals%2Fminetest.git diff --git a/src/settings.h b/src/settings.h index e8f376938..4bc22eaa1 100644 --- a/src/settings.h +++ b/src/settings.h @@ -31,6 +31,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #include #include "debug.h" #include "utility.h" +#include "log.h" enum ValueType { @@ -77,11 +78,11 @@ public: std::string trimmedline = trim(line); - // Ignore comments - if(trimmedline[0] == '#') + // Ignore empty lines and comments + if(trimmedline.size() == 0 || trimmedline[0] == '#') return true; - //dstream<<"trimmedline=\""< \""< objects; @@ -246,7 +247,7 @@ public: std::ifstream is(filename); if(is.good() == false) { - dstream<<"INFO: updateConfigFile():" + infostream<<"updateConfigFile():" " Error opening configuration file" " for reading: \"" <getKey(); std::string value = i.getNode()->getValue(); - dstream<<"Adding \""< expected."<= argc) { - dstream<<"Invalid command-line parameter \"" + errorstream<<"Invalid command-line parameter \"" <