From 98b4103b868f97a01793b70f1cdb7a555519cd82 Mon Sep 17 00:00:00 2001 From: Splatt581 <31417200+Splatt581@users.noreply.github.com> Date: Fri, 4 Apr 2025 01:08:30 +0300 Subject: [PATCH] Added check for invalid utf8 chars in userinfo (#1074) --- rehlds/engine/info.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/rehlds/engine/info.cpp b/rehlds/engine/info.cpp index 6680d35..d0a36e3 100644 --- a/rehlds/engine/info.cpp +++ b/rehlds/engine/info.cpp @@ -856,6 +856,12 @@ qboolean Info_IsValid(const char *s) return false; }; + // invalid utf8 chars are deprecated + if (!Q_UnicodeValidate(s)) + { + return FALSE; + } + while (*s == '\\') { const char* key = ++s;