diff options
Diffstat (limited to 'src/configparser.cpp')
| -rw-r--r-- | src/configparser.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/configparser.cpp b/src/configparser.cpp index e05dcd6ff..e5a12d319 100644 --- a/src/configparser.cpp +++ b/src/configparser.cpp @@ -755,6 +755,16 @@ bool ConfigTag::getBool(const std::string &key, bool def) return def; } +unsigned char ConfigTag::getCharacter(const std::string &key, unsigned char def) +{ + std::string result; + if (!readString(key, result) || result.size() != 1) + return def; + + return result[0]; +} + + std::string ConfigTag::getTagLocation() { return src_name + ":" + ConvToStr(src_line); |
