diff options
| author | Mat M <mathew1800@gmail.com> | 2017-01-31 21:53:12 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2017-01-31 21:53:12 -0500 |
| commit | 84d81a4b7a9622e00c723fa8aec648f7b71e2717 (patch) | |
| tree | 2ce45ceba08d14ccb5f17f7953229aefd2e5eff0 /Source/Core | |
| parent | 5b782b9f2d4314962a33b42e46264bbf7f221543 (diff) | |
| parent | 44196f6a55ef89db917075fb5d7beeda4635b0fa (diff) | |
Merge pull request #4792 from sepalani/fix_isctype_assert
Fixes std::isprint undefined behavior
Diffstat (limited to 'Source/Core')
| -rw-r--r-- | Source/Core/Core/Core.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Source/Core/Core/Core.cpp b/Source/Core/Core/Core.cpp index 6eba2560cf..c32b0b6d33 100644 --- a/Source/Core/Core/Core.cpp +++ b/Source/Core/Core/Core.cpp @@ -5,8 +5,8 @@ #include "Core/Core.h" #include <atomic> -#include <cctype> #include <cstring> +#include <locale> #include <mutex> #include <queue> #include <utility> @@ -178,7 +178,7 @@ void DisplayMessage(const std::string& message, int time_in_ms) // Actually displaying non-ASCII could cause things to go pear-shaped for (const char& c : message) { - if (!std::isprint(c)) + if (!std::isprint(c, std::locale::classic())) return; } |
