From cdb764f2de7ee27c97708dfe44f1e6b905c571db Mon Sep 17 00:00:00 2001 From: Attila Molnar Date: Thu, 26 Nov 2015 13:50:28 +0100 Subject: Fix FORMAT_INTERNAL handling in LocalIntExt::serialize() and LocalStringExt::serialize() --- src/base.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/base.cpp') diff --git a/src/base.cpp b/src/base.cpp index c268c7493..b007a1098 100644 --- a/src/base.cpp +++ b/src/base.cpp @@ -238,7 +238,7 @@ LocalStringExt::~LocalStringExt() std::string LocalStringExt::serialize(SerializeFormat format, const Extensible* container, void* item) const { - if (item && format == FORMAT_USER) + if ((item) && (format != FORMAT_NETWORK)) return *static_cast(item); return ""; } @@ -254,7 +254,7 @@ LocalIntExt::~LocalIntExt() std::string LocalIntExt::serialize(SerializeFormat format, const Extensible* container, void* item) const { - if (format != FORMAT_USER) + if (format == FORMAT_NETWORK) return ""; return ConvToStr(reinterpret_cast(item)); } -- cgit v1.2.3