(svn r1110) -Fix: Empty console commands were executed and returned error message (sign_de for GeniusDex)
authordarkvater
Wed, 15 Dec 2004 21:30:20 +0000
changeset 672 9089c74ba6c9
parent 671 6f1d8c908156
child 673 beb1e1eb298c
(svn r1110) -Fix: Empty console commands were executed and returned error message (sign_de for GeniusDex)
console.c
--- a/console.c	Wed Dec 15 21:25:33 2004 +0000
+++ b/console.c	Wed Dec 15 21:30:20 2004 +0000
@@ -193,7 +193,9 @@
 					IConsolePrintF(_iconsole_color_commands, "] %s", _iconsole_cmdline);
 					_iconsole_cmdbufferpos = 19;
 					IConsoleCmdBufferAdd(_iconsole_cmdline);
-					IConsoleCmdExec(_iconsole_cmdline);
+					if (strlen(_iconsole_cmdline) != 0) // only execute if there is something typed obviously
+						IConsoleCmdExec(_iconsole_cmdline);
+
 					IConsoleClearCommand();
 					break;
 				case WKC_CTRL | WKC_RETURN: