Revert some uses of xsprintf
This reverts some changes introduced in d054f0a4d4.
xsprintf should be used in cases where we calculated the right buffer
size by hand (using DECIMAL_STRING_MAX and such), and never in cases where
we are printing externally specified strings of arbitrary length.
Fixes #4534.
This commit is contained in:
+1
-1
@@ -782,7 +782,7 @@ static void log_assert(
|
||||
return;
|
||||
|
||||
DISABLE_WARNING_FORMAT_NONLITERAL;
|
||||
xsprintf(buffer, format, text, file, line, func);
|
||||
snprintf(buffer, sizeof buffer, format, text, file, line, func);
|
||||
REENABLE_WARNING;
|
||||
|
||||
log_abort_msg = buffer;
|
||||
|
||||
Reference in New Issue
Block a user