diff options
author | tma <tma@edf5b092-35ff-0310-97b2-ce42778d08ea> | 2005-09-19 17:45:29 +0000 |
---|---|---|
committer | tma <tma@edf5b092-35ff-0310-97b2-ce42778d08ea> | 2005-09-19 17:45:29 +0000 |
commit | 275b73aa64da7c4b5083216d273877380ceebe73 (patch) | |
tree | 6e26bdbc5a43c5d26a21d090ff4e9840ed61670b /code/client | |
parent | 9170f3b736b0cfd2818333cf60e2c4ff1959e30f (diff) | |
download | ioquake3-aero-275b73aa64da7c4b5083216d273877380ceebe73.tar.gz ioquake3-aero-275b73aa64da7c4b5083216d273877380ceebe73.zip |
* Fix to multiple buffer overflow bugs in CL_Rcon_f
* Fix to COM_ParseExt 1 byte overwrite bug
* Fixed some missing calls to trap_FS_FCloseFile
* Fixed q3msgboom and q3infoboom bugs
* Fixed some qboolean type confusion
* Above fixes from http://www.quakesrc.org/forums/viewtopic.php?t=5374
git-svn-id: svn://svn.icculus.org/quake3/trunk@95 edf5b092-35ff-0310-97b2-ce42778d08ea
Diffstat (limited to 'code/client')
-rw-r--r-- | code/client/cl_keys.c | 4 | ||||
-rw-r--r-- | code/client/cl_main.c | 11 | ||||
-rw-r--r-- | code/client/keys.h | 2 |
3 files changed, 9 insertions, 8 deletions
diff --git a/code/client/cl_keys.c b/code/client/cl_keys.c index 1ccfc52..cf14d97 100644 --- a/code/client/cl_keys.c +++ b/code/client/cl_keys.c @@ -42,7 +42,7 @@ int chat_playerNum; qboolean key_overstrikeMode; -qboolean anykeydown; +int anykeydown; qkey_t keys[MAX_KEYS]; @@ -1238,7 +1238,7 @@ void Key_ClearStates (void) { int i; - anykeydown = qfalse; + anykeydown = 0; for ( i=0 ; i < MAX_KEYS ; i++ ) { if ( keys[i].down ) { diff --git a/code/client/cl_main.c b/code/client/cl_main.c index 21075f2..d890275 100644 --- a/code/client/cl_main.c +++ b/code/client/cl_main.c @@ -1090,6 +1090,7 @@ void CL_Connect_f( void ) { Cvar_Set( "cl_currentServerAddress", server ); } +#define MAX_RCON_MESSAGE 1024 /* ===================== @@ -1100,7 +1101,7 @@ CL_Rcon_f ===================== */ void CL_Rcon_f( void ) { - char message[1024]; + char message[MAX_RCON_MESSAGE]; netadr_t to; if ( !rcon_client_password->string ) { @@ -1115,13 +1116,13 @@ void CL_Rcon_f( void ) { message[3] = -1; message[4] = 0; - strcat (message, "rcon "); + Q_strcat (message, MAX_RCON_MESSAGE, "rcon "); - strcat (message, rcon_client_password->string); - strcat (message, " "); + Q_strcat (message, MAX_RCON_MESSAGE, rcon_client_password->string); + Q_strcat (message, MAX_RCON_MESSAGE, " "); // https://zerowing.idsoftware.com/bugzilla/show_bug.cgi?id=543 - strcat (message, Cmd_Cmd()+5); + Q_strcat (message, MAX_RCON_MESSAGE, Cmd_Cmd()+5); if ( cls.state >= CA_CONNECTED ) { to = clc.netchan.remoteAddress; diff --git a/code/client/keys.h b/code/client/keys.h index c852f5a..3a13107 100644 --- a/code/client/keys.h +++ b/code/client/keys.h @@ -43,7 +43,7 @@ extern field_t historyEditLines[COMMAND_HISTORY]; extern field_t g_consoleField; extern field_t chatField; -extern qboolean anykeydown; +extern int anykeydown; extern qboolean chat_team; extern int chat_playerNum; |