This commit is contained in:
Malcolm Tyrrell
2021-05-12 12:55:21 +01:00
parent 813d0aecdd
commit 58bc4bcb63
4 changed files with 20 additions and 16 deletions
+5 -4
View File
@@ -187,13 +187,14 @@ void Logger::verboseDebug(const char *message) {
}
// ----------------------------------------------------------------------------------
void Logger::info(const char *message) {
void Logger::infoInternal(Assimp::Formatter::format f) {
std::string message = f;
// TODO: Should limit sizes in the formatter.
// SECURITY FIX: see above
if (strlen(message) > MAX_LOG_MESSAGE_LENGTH) {
if (message.length() > MAX_LOG_MESSAGE_LENGTH) {
return;
}
return OnInfo(message);
return OnInfo(message.c_str());
}
// ----------------------------------------------------------------------------------