summaryrefslogtreecommitdiff
path: root/src/game/g_admin.c
diff options
context:
space:
mode:
authorChristopher Schwarz <lakitu7@gmail.com>2009-10-09 03:03:37 +0000
committerTim Angus <tim@ngus.net>2013-01-03 00:16:43 +0000
commit7161853405320ed0ccbb61fbf53fb4691fbd0623 (patch)
tree7feff93eb12c51f70347855e8f7df2b16a39b99a /src/game/g_admin.c
parentbd1001553ce4c30a717c1dc00919ffc51db09510 (diff)
* Disallow the name "console" to prevent confusion with dedicated server console messaging functions
Diffstat (limited to 'src/game/g_admin.c')
-rw-r--r--src/game/g_admin.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/game/g_admin.c b/src/game/g_admin.c
index 8df377ea..832d3c45 100644
--- a/src/game/g_admin.c
+++ b/src/game/g_admin.c
@@ -270,6 +270,12 @@ qboolean G_admin_name_check( gentity_t *ent, char *name, char *err, int len )
if( !strcmp( name2, "unnamedplayer" ) )
return qtrue;
+ if( !strcmp( name2, "console" ) )
+ {
+ Q_strncpyz( err, "The name 'console' is not allowed.", len );
+ return qfalse;
+ }
+
G_DecolorString( name, testName, sizeof( testName ) );
if( isdigit( testName[ 0 ] ) )
{