From c3d34e8656de0d6821bee72f9257de26aafed8c1 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Tue, 21 Sep 2021 14:18:23 -0400 Subject: [PATCH] only accept lower case to be consistent with the rest of the input --- src/utils.cpp | 1 - src/utils.h | 4 ++-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/src/utils.cpp b/src/utils.cpp index d5122db425..2feba5db97 100644 --- a/src/utils.cpp +++ b/src/utils.cpp @@ -372,7 +372,6 @@ int utils::logical(const char *file, int line, const char *str, bool do_abort, L // convert to ascii and lowercase std::string buf(str); if (has_utf8(buf)) buf = utf8_subst(buf); - std::transform(buf.begin(), buf.end(), buf.begin(), tolower); int rv = 0; if ((buf == "yes") || (buf == "on") || (buf == "true") || (buf == "1")) { diff --git a/src/utils.h b/src/utils.h index 79f20c7186..4dd4eea090 100644 --- a/src/utils.h +++ b/src/utils.h @@ -159,8 +159,8 @@ namespace utils { LAMMPS *lmp); /*! Convert a string to a boolean while checking whether it is a valid boolean term. - * Valid terms are 'yes', 'no', 'true', 'false', 'on', 'off', '1', '0'. Capitalization - * will be ignored (thus 'yEs' or 'nO' are valid, 'yeah' or 'nope' are not). + * Valid terms are 'yes', 'no', 'true', 'false', 'on', 'off', and '1', '0'. Only + * lower case is accepted. * * \param file name of source file for error message * \param line line number in source file for error message