diff options
author | /dev/humancontroller <devhc@example.com> | 2015-03-18 14:53:02 +0100 |
---|---|---|
committer | /dev/humancontroller <devhc@example.com> | 2017-03-09 13:51:08 +0100 |
commit | cf75fd58b8bccaddbffa0bb791ea3287515dfee5 (patch) | |
tree | 5475e9aa96fbd8f26b365ccd8181c90af7328bad | |
parent | 5e0f74ed9df36ba5d58aeb13cce527047e572b90 (diff) |
fix Com_ClientListParse()
-rw-r--r-- | src/qcommon/q_shared.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/qcommon/q_shared.c b/src/qcommon/q_shared.c index f5888633..933df9eb 100644 --- a/src/qcommon/q_shared.c +++ b/src/qcommon/q_shared.c @@ -1537,6 +1537,7 @@ Com_ClientListParse */ void Com_ClientListParse( clientList_t *list, const char *s ) { + char t[ 9 ]; if( !list ) return; list->lo = 0; @@ -1545,5 +1546,7 @@ void Com_ClientListParse( clientList_t *list, const char *s ) return; if( strlen( s ) != 16 ) return; - sscanf( s, "%x%x", &list->hi, &list->lo ); + Q_strncpyz( t, s, 9 ); + sscanf( t, "%x", &list->hi ); + sscanf( s + 8, "%x", &list->lo ); } |