r517 - trunk/code/unix
DONOTREPLY at icculus.org
DONOTREPLY at icculus.org
Sun Jan 22 14:38:51 EST 2006
Author: tma
Date: 2006-01-22 14:38:50 -0500 (Sun, 22 Jan 2006)
New Revision: 517
Modified:
trunk/code/unix/unix_main.c
Log:
* The use of va in the ansi color stuff was preventing developer 1 mode (and
probably various other things) from working properly
Modified: trunk/code/unix/unix_main.c
===================================================================
--- trunk/code/unix/unix_main.c 2006-01-22 17:07:21 UTC (rev 516)
+++ trunk/code/unix/unix_main.c 2006-01-22 19:38:50 UTC (rev 517)
@@ -1221,6 +1221,7 @@
int msgLength, pos;
int i, j;
char *escapeCode;
+ char tempBuffer[ 7 ];
if( !msg || !buffer )
return;
@@ -1234,7 +1235,8 @@
{
if( msg[ i ] == '\n' )
{
- strncat( buffer, va( "%c[0m\n", 0x1B ), bufferSize );
+ Com_sprintf( tempBuffer, 7, "%c[0m\n", 0x1B );
+ strncat( buffer, tempBuffer, bufferSize );
i++;
}
else if( msg[ i ] == Q_COLOR_ESCAPE )
@@ -1254,13 +1256,19 @@
}
if( escapeCode )
- strncat( buffer, va( "%c[%sm", 0x1B, escapeCode ), bufferSize );
+ {
+ Com_sprintf( tempBuffer, 7, "%c[%sm", 0x1B, escapeCode );
+ strncat( buffer, tempBuffer, bufferSize );
+ }
i++;
}
}
else
- strncat( buffer, va( "%c", msg[ i++ ] ), bufferSize );
+ {
+ Com_sprintf( tempBuffer, 7, "%c", msg[ i++ ] );
+ strncat( buffer, tempBuffer, bufferSize );
+ }
}
}
More information about the quake3-commits
mailing list