From 0269e366f13104ccd4e2e50475460b032006730a Mon Sep 17 00:00:00 2001 From: Andrew Dunai Date: Sun, 4 Mar 2018 19:45:33 +0200 Subject: [PATCH] Fix garbage in string padding. --- core/io/marshalls.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/io/marshalls.cpp b/core/io/marshalls.cpp index 9e212877800f..2ebe8d6df7e1 100644 --- a/core/io/marshalls.cpp +++ b/core/io/marshalls.cpp @@ -813,7 +813,7 @@ static void _encode_string(const String &p_string, uint8_t *&buf, int &r_len) { while (r_len % 4) { r_len++; //pad if (buf) { - buf++; + *(buf++) = 0; } } }