summaryrefslogtreecommitdiff
path: root/src/ui
diff options
context:
space:
mode:
Diffstat (limited to 'src/ui')
-rw-r--r--src/ui/ui_atoms.c12
-rw-r--r--src/ui/ui_shared.c4
2 files changed, 8 insertions, 8 deletions
diff --git a/src/ui/ui_atoms.c b/src/ui/ui_atoms.c
index 71374ab3..822cecfd 100644
--- a/src/ui/ui_atoms.c
+++ b/src/ui/ui_atoms.c
@@ -35,9 +35,9 @@ void QDECL Com_Error( int level, const char *error, ... )
va_list argptr;
char text[1024];
- va_start ( argptr, error );
- vsprintf ( text, error, argptr );
- va_end ( argptr );
+ va_start( argptr, error );
+ Q_vsnprintf( text, sizeof( text ), error, argptr );
+ va_end( argptr );
trap_Error( va( "%s", text ) );
}
@@ -47,9 +47,9 @@ void QDECL Com_Printf( const char *msg, ... )
va_list argptr;
char text[1024];
- va_start ( argptr, msg );
- vsprintf ( text, msg, argptr );
- va_end ( argptr );
+ va_start( argptr, msg );
+ Q_vsnprintf( text, sizeof( text ), msg, argptr );
+ va_end( argptr );
trap_Print( va( "%s", text ) );
}
diff --git a/src/ui/ui_shared.c b/src/ui/ui_shared.c
index 5d883ec6..c6a5ba46 100644
--- a/src/ui/ui_shared.c
+++ b/src/ui/ui_shared.c
@@ -325,7 +325,7 @@ void PC_SourceWarning( int handle, char *format, ... )
static char string[4096];
va_start( argptr, format );
- vsprintf( string, format, argptr );
+ Q_vsnprintf( string, sizeof( string ), format, argptr );
va_end( argptr );
filename[0] = '\0';
@@ -348,7 +348,7 @@ void PC_SourceError( int handle, char *format, ... )
static char string[4096];
va_start( argptr, format );
- vsprintf( string, format, argptr );
+ Q_vsnprintf( string, sizeof( string ), format, argptr );
va_end( argptr );
filename[0] = '\0';