[python] Test: fix printText

This commit is contained in:
Émilie Feral
2020-04-01 15:40:51 +02:00
committed by LeaNumworks
parent d0a77bda2b
commit ec5803f06f

View File

@@ -7,7 +7,8 @@ char TestExecutionEnvironment::s_pythonHeap[TestExecutionEnvironment::s_pythonHe
void TestExecutionEnvironment::printText(const char * text, size_t length) {
assert(m_printTextIndex + length < k_maxPrintedTextSize);
m_printTextIndex += strlcpy(m_printTextBuffer + m_printTextIndex, text, length + 1);
strlcpy(m_printTextBuffer + m_printTextIndex, text, length + 1);
m_printTextIndex += length;
m_printTextBuffer[m_printTextIndex] = 0;
}