aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorthilo <thilo@edf5b092-35ff-0310-97b2-ce42778d08ea>2006-06-11 14:56:58 +0000
committerthilo <thilo@edf5b092-35ff-0310-97b2-ce42778d08ea>2006-06-11 14:56:58 +0000
commit1bf90e5ce6b77e61ea5ce01172f14d0916b27a1c (patch)
treec6b99138fb825db80b6ccd38a59892373692966a
parentca1b5b399e8a61bd3e578f4230b08ed1f8d7ff89 (diff)
downloadioquake3-aero-1bf90e5ce6b77e61ea5ce01172f14d0916b27a1c.tar.gz
ioquake3-aero-1bf90e5ce6b77e61ea5ce01172f14d0916b27a1c.zip
Fix client "freezes" if a user with ASCII characters > 127 enters a server. Reported by tjw
git-svn-id: svn://svn.icculus.org/quake3/trunk@803 edf5b092-35ff-0310-97b2-ce42778d08ea
-rw-r--r--code/qcommon/msg.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/code/qcommon/msg.c b/code/qcommon/msg.c
index d16fd58..c6290a0 100644
--- a/code/qcommon/msg.c
+++ b/code/qcommon/msg.c
@@ -492,6 +492,11 @@ char *MSG_ReadStringLine( msg_t *msg ) {
if ( c == '%' ) {
c = '.';
}
+ // don't allow higher ascii values
+ if ( c > 127 ) {
+ c = '.';
+ }
+
string[l] = c;
l++;
} while (l < sizeof(string)-1);