Avoid overflowing CONS_Printf's buffer by using vsnprintf

This commit is contained in:
indev committed 2024-12-12 18:47:35 +03:00
1 parent 1cbfc71fc6
commit 939084d57b
1 file changed
+1 -1
+1 -1
View File
@@ -1236,7 +1236,7 @@ void CONS_Printf(const char *fmt, ...)
txt = malloc(8192);
va_start(argptr, fmt);
vsprintf(txt, fmt, argptr);
vsnprintf(txt, 8192, fmt, argptr);
va_end(argptr);
// echo console prints to log file