diff options
author | LogicParrot <LogicParrot@users.noreply.github.com> | 2016-02-16 16:26:18 +0100 |
---|---|---|
committer | LogicParrot <LogicParrot@users.noreply.github.com> | 2016-02-16 16:26:18 +0100 |
commit | 7d09fcbd2f87857abad4ea9fbb4f386aa0b44d89 (patch) | |
tree | e581875b2dde7280c70e929775c237fcda66c0e8 /src | |
parent | Merge pull request #2985 from marvinkopf/poweredrail (diff) | |
parent | Fix unicode handling in StringUtils::TrimString (diff) | |
download | cuberite-7d09fcbd2f87857abad4ea9fbb4f386aa0b44d89.tar cuberite-7d09fcbd2f87857abad4ea9fbb4f386aa0b44d89.tar.gz cuberite-7d09fcbd2f87857abad4ea9fbb4f386aa0b44d89.tar.bz2 cuberite-7d09fcbd2f87857abad4ea9fbb4f386aa0b44d89.tar.lz cuberite-7d09fcbd2f87857abad4ea9fbb4f386aa0b44d89.tar.xz cuberite-7d09fcbd2f87857abad4ea9fbb4f386aa0b44d89.tar.zst cuberite-7d09fcbd2f87857abad4ea9fbb4f386aa0b44d89.zip |
Diffstat (limited to 'src')
-rw-r--r-- | src/StringUtils.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/StringUtils.cpp b/src/StringUtils.cpp index 76b9fdbde..8ea94ecd7 100644 --- a/src/StringUtils.cpp +++ b/src/StringUtils.cpp @@ -222,7 +222,7 @@ AString TrimString(const AString & str) size_t start = 0; while (start < len) { - if (str[start] > 32) + if (static_cast<unsigned char>(str[start]) > 32) { break; } @@ -236,7 +236,7 @@ AString TrimString(const AString & str) size_t end = len; while (end >= start) { - if (str[end] > 32) + if (static_cast<unsigned char>(str[end]) > 32) { break; } |