Skip to content

Commit c26bae4

Browse files
Fix LoggingTest build on some platforms with some build config
1 parent b429605 commit c26bae4

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

tests/aws-cpp-sdk-core-tests/utils/logging/LoggingTest.cpp

+4
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,10 @@ class MockCRTLogSystem : public DefaultCRTLogSystem
8484
va_end(tmp_args);
8585

8686
Array<char> outputBuff(requiredLength);
87+
if(!outputBuff.GetUnderlyingData() || !outputBuff.GetLength()) {
88+
assert(!"Failed to allocate mock outputBuff!");
89+
return;
90+
}
8791
#ifdef _WIN32
8892
vsnprintf_s(outputBuff.GetUnderlyingData(), outputBuff.GetLength(), _TRUNCATE, formatStr, args);
8993
#else

0 commit comments

Comments
 (0)