Skip to content

Commit

Permalink
Fixed: Attempts to add/subtract on an unknown cvar produce no error m…
Browse files Browse the repository at this point in the history
…essage
  • Loading branch information
danij-deng committed Oct 22, 2011
1 parent 110cbeb commit 28986b5
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion doomsday/engine/portable/src/con_main.c
Expand Up @@ -2224,11 +2224,15 @@ static boolean cvarAddSub(const char* name, float delta, boolean force)
float val;

if(!cvar)
{
if(name && name[0])
Con_Printf("%s is not a known (cvar) name.\n", name);
return false;
}

if(cvar->flags & CVF_READ_ONLY)
{
Con_Printf("%s (cvar) is read-only. It can not be changed (not even with force)\n", name);
Con_Printf("%s (cvar) is read-only. It can not be changed (not even with force).\n", name);
return false;
}

Expand Down

0 comments on commit 28986b5

Please sign in to comment.