(svn r4434) - Codechange: use str_validate for the console as well instead of custom function doing the same.
authorDarkvater
Sat, 15 Apr 2006 19:52:58 +0000
changeset 3559 1d4b8eb9b493
parent 3558 36ca79c931f2
child 3560 4389ae5ad967
(svn r4434) - Codechange: use str_validate for the console as well instead of custom function doing the same.
console.c
--- a/console.c	Sat Apr 15 18:57:58 2006 +0000
+++ b/console.c	Sat Apr 15 19:52:58 2006 +0000
@@ -395,11 +395,7 @@
 	memmove(&_iconsole_buffer[0], &_iconsole_buffer[1], sizeof(_iconsole_buffer[0]) * ICON_BUFFER);
 	_iconsole_buffer[ICON_BUFFER] = strdup(string);
 
-	{ // filter out unprintable characters
-		char *i;
-		for (i = _iconsole_buffer[ICON_BUFFER]; *i != '\0'; i++)
-			if (!IsValidAsciiChar((byte)*i)) *i = ' ';
-	}
+	str_validate(_iconsole_buffer[ICON_BUFFER]);
 
 	memmove(&_iconsole_cbuffer[0], &_iconsole_cbuffer[1], sizeof(_iconsole_cbuffer[0]) * ICON_BUFFER);
 	_iconsole_cbuffer[ICON_BUFFER] = color_code;