test/UnitHTTP.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
New commits: commit 48c4d3a136a8e443042fa56dcba3f5ca2d792dc3 Author: Miklos Vajna <vmik...@collabora.com> AuthorDate: Wed May 22 15:14:48 2019 +0200 Commit: Andras Timar <andras.ti...@collabora.com> CommitDate: Wed Jul 10 13:17:47 2019 +0200 test: avoid variable-sized object initialization UnitHTTP.cpp:94:21: error: variable-sized object may not be initialized char buffer[str.size() + 64] = { 0, }; ^~~~~~~~~~~~~~~ Change-Id: I2e6c8b4ca123ac5bf6391aa460069d24066f728d diff --git a/test/UnitHTTP.cpp b/test/UnitHTTP.cpp index 1bd3f5437..4dfe58702 100644 --- a/test/UnitHTTP.cpp +++ b/test/UnitHTTP.cpp @@ -92,7 +92,8 @@ public: bool expectString(const std::shared_ptr<Poco::Net::StreamSocket> &socket, std::string str) { - char buffer[str.size() + 64] = { 0, }; + char buffer[str.size() + 64]; + memset(&buffer, 0, sizeof(buffer)); int got = socket->receiveBytes(buffer, str.size()); if (got != (int)str.size() || strncmp(buffer, str.c_str(), got)) _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits