Update dependencies

This commit is contained in:
momo5502 2016-08-25 13:25:23 +02:00
parent 3ff2c40f7a
commit 7f951dadbd
4 changed files with 10 additions and 5 deletions

2
deps/fmt vendored

@ -1 +1 @@
Subproject commit 93975c70bb373cd2d31361a1963384424aff0319 Subproject commit d775a20fff0be6e087dd3a160e1b662606b9247e

2
deps/mongoose vendored

@ -1 +1 @@
Subproject commit fd839f18275e5fde419497a254c129c6ad764b42 Subproject commit 2deaf084e4dc0214be55b29f964c3d69bbdf6b21

2
deps/protobuf vendored

@ -1 +1 @@
Subproject commit ff2a6600e5df21683b86aca7e30bbb80c0aed848 Subproject commit b97a4a53cdd55be74c30badefeb132a091764f53

View File

@ -12,10 +12,15 @@ namespace Utils
static int g_vaNextBufferIndex = 0; static int g_vaNextBufferIndex = 0;
char* buffer = g_vaBuffer[g_vaNextBufferIndex]; char* buffer = g_vaBuffer[g_vaNextBufferIndex];
std::string str = fmt::sprintf(message, std::forward<Args>(args)...);
strncpy_s(g_vaBuffer[g_vaNextBufferIndex], str.data(), VA_BUFFER_SIZE);
g_vaNextBufferIndex = (g_vaNextBufferIndex + 1) % VA_BUFFER_COUNT; g_vaNextBufferIndex = (g_vaNextBufferIndex + 1) % VA_BUFFER_COUNT;
std::string str = fmt::sprintf(message, std::forward<Args>(args)...);
if (memmove_s(buffer, VA_BUFFER_SIZE, str.data(), str.size() + 1))
{
*buffer = 0; // Error
}
return buffer; return buffer;
} }