summaryrefslogtreecommitdiff
path: root/core
diff options
context:
space:
mode:
authorLeon Krause <lk@leonkrause.com>2017-10-08 20:13:46 +0200
committerLeon Krause <lk@leonkrause.com>2017-10-08 20:13:46 +0200
commitc05c334de7eda2318afc4fb003dcdd7d2d74db3e (patch)
treef4e41595333d343dbe36f224054392a95b9a430c /core
parent2e6f2ed0325c65c2b623532bb3b7e191064fe937 (diff)
Fix binary marshalling of Objects
Diffstat (limited to 'core')
-rw-r--r--core/io/marshalls.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/core/io/marshalls.cpp b/core/io/marshalls.cpp
index 0834d6c321..d388a622de 100644
--- a/core/io/marshalls.cpp
+++ b/core/io/marshalls.cpp
@@ -1140,8 +1140,9 @@ Error encode_variant(const Variant &p_variant, uint8_t *r_buffer, int &r_len, bo
if (buf) {
encode_uint32(0, buf);
buf += 4;
- r_len += 4;
}
+ r_len += 4;
+
} else {
_encode_string(obj->get_class(), buf, r_len);