Merge branch 'development' into cmake/warn_virtual
Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com> # Conflicts: # Code/Legacy/CryCommon/IConsole.h # Code/Legacy/CrySystem/LocalizedStringManager.h # Code/Legacy/CrySystem/XConsole.h # Code/Legacy/CrySystem/XConsoleVariable.h # Code/Legacy/CrySystem/XML/XmlUtils.cpp # cmake/Platform/Common/Clang/Configurations_clang.cmake
This commit is contained in:
@@ -18,7 +18,7 @@ namespace AZ
|
||||
{
|
||||
void OutputToDebugger([[maybe_unused]] const char* window, [[maybe_unused]] const char* message)
|
||||
{
|
||||
__android_log_print(ANDROID_LOG_INFO, window, message);
|
||||
__android_log_print(ANDROID_LOG_INFO, window, "%s", message);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -311,7 +311,6 @@ namespace AzFramework
|
||||
// On some platforms, threadid is just a number but on other platforms it is a pointer of some kind
|
||||
// uintptr_t will ensure that the data will always fit
|
||||
uintptr_t threadID = threadId ? threadId : (uintptr_t)(AZStd::this_thread::get_id().m_id);
|
||||
const char* printFormatter = m_machineReadable ? "~~%p~~%s~~" : "{%p}[%14s]";
|
||||
// while it may be tempting to check the fileio Pointer here, any emit of any warning or error would be fatal
|
||||
// since we're already logging, and we don't want to log while you log.
|
||||
|
||||
@@ -331,7 +330,14 @@ namespace AzFramework
|
||||
|
||||
azsnprintf(buffer, 80, "~~%llu~~%i", rawTime, severity);
|
||||
m_fileIO->Write(m_fileHandle, buffer, strlen(buffer));
|
||||
azsnprintf(buffer, 80, printFormatter, threadID, categoryActual);
|
||||
if (m_machineReadable) // Branching instead of using a ternary on the format string to avoid warning 4774 (format literal expected)
|
||||
{
|
||||
azsnprintf(buffer, 80, "~~%p~~%s~~", reinterpret_cast<void*>(threadID), categoryActual);
|
||||
}
|
||||
else
|
||||
{
|
||||
azsnprintf(buffer, 80, "{%p}[%14s]", reinterpret_cast<void*>(threadID), categoryActual);
|
||||
}
|
||||
m_fileIO->Write(m_fileHandle, buffer, strlen(buffer));
|
||||
|
||||
m_fileIO->Write(m_fileHandle, dataSource, dataLength);
|
||||
@@ -349,8 +355,14 @@ namespace AzFramework
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
azsnprintf(categorybuffer, 64, printFormatter, threadID, categoryActual);
|
||||
if (m_machineReadable) // Branching instead of using a ternary on the format string to avoid warning 4774 (format literal expected)
|
||||
{
|
||||
azsnprintf(categorybuffer, 64, "~~%p~~%s~~", reinterpret_cast<void*>(threadID), categoryActual);
|
||||
}
|
||||
else
|
||||
{
|
||||
azsnprintf(categorybuffer, 64, "{%p}[%14s]", reinterpret_cast<void*>(threadID), categoryActual);
|
||||
}
|
||||
|
||||
if ((category) && (categoryLen))
|
||||
{
|
||||
|
||||
+3
-4
@@ -92,8 +92,7 @@ namespace AzManipulatorTestFramework
|
||||
{
|
||||
if (m_logging)
|
||||
{
|
||||
AZStd::string message = AZStd::string::format(format, args...);
|
||||
AZ_Printf("[ActionDispatcher] %s", message.c_str());
|
||||
AZ_Printf("ActionDispatcher", format, args...);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -150,7 +149,7 @@ namespace AzManipulatorTestFramework
|
||||
template <typename DerivedDispatcherT>
|
||||
DerivedDispatcherT* ActionDispatcher<DerivedDispatcherT>::MouseLButtonDown()
|
||||
{
|
||||
Log("Mouse left button down");
|
||||
Log("%s", "Mouse left button down");
|
||||
MouseLButtonDownImpl();
|
||||
return static_cast<DerivedDispatcherT*>(this);
|
||||
}
|
||||
@@ -158,7 +157,7 @@ namespace AzManipulatorTestFramework
|
||||
template <typename DerivedDispatcherT>
|
||||
DerivedDispatcherT* ActionDispatcher<DerivedDispatcherT>::MouseLButtonUp()
|
||||
{
|
||||
Log("Mouse left button up");
|
||||
Log("%s", "Mouse left button up");
|
||||
MouseLButtonUpImpl();
|
||||
return static_cast<DerivedDispatcherT*>(this);
|
||||
}
|
||||
|
||||
@@ -24,7 +24,7 @@ namespace AzManipulatorTestFramework
|
||||
{
|
||||
const char* error = "Couldn't add action to sequence, dispatcher is locked (you must call ResetSequence() \
|
||||
before adding actions to this dispatcher)";
|
||||
Log(error);
|
||||
Log("%s", error);
|
||||
AZ_Assert(false, "Error: %s", error);
|
||||
}
|
||||
|
||||
@@ -108,7 +108,7 @@ namespace AzManipulatorTestFramework
|
||||
|
||||
RetainedModeActionDispatcher* RetainedModeActionDispatcher::ResetSequence()
|
||||
{
|
||||
Log("Resetting the action sequence");
|
||||
Log("%s", "Resetting the action sequence");
|
||||
m_actions.clear();
|
||||
m_dispatcher.ResetEvent();
|
||||
m_locked = false;
|
||||
|
||||
Reference in New Issue
Block a user