aboutsummaryrefslogtreecommitdiff
path: root/zenserver/cache/structuredcache.cpp
diff options
context:
space:
mode:
authorPer Larsson <[email protected]>2021-11-12 14:36:34 +0100
committerPer Larsson <[email protected]>2021-11-12 14:36:34 +0100
commit58bec60cd39b697d5cd3ab6c757a92e528a638fc (patch)
tree5989b20e3a3ac8b3adb22805e25f4622fa69ee79 /zenserver/cache/structuredcache.cpp
parentMovec cache utility types to zenutil and fixed unit tests. (diff)
downloadzen-58bec60cd39b697d5cd3ab6c757a92e528a638fc.tar.xz
zen-58bec60cd39b697d5cd3ab6c757a92e528a638fc.zip
Fixed bug when cloning CbObject.
Diffstat (limited to 'zenserver/cache/structuredcache.cpp')
-rw-r--r--zenserver/cache/structuredcache.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/zenserver/cache/structuredcache.cpp b/zenserver/cache/structuredcache.cpp
index 1b6406562..d3da98620 100644
--- a/zenserver/cache/structuredcache.cpp
+++ b/zenserver/cache/structuredcache.cpp
@@ -919,7 +919,8 @@ HttpStructuredCacheService::HandleRpcGetCacheRecords(zen::HttpServerRequest& Req
ToString(HttpContentType::kCbObject));
ZEN_ASSERT(Params.KeyIndex < CacheValues.size());
- CacheValues[Params.KeyIndex] = IoBufferBuilder::MakeCloneFromMemory(Params.Record.GetView());
+
+ CacheValues[Params.KeyIndex] = CbObject::Clone(Params.Record).GetBuffer().AsIoBuffer();
m_CacheStats.HitCount++;
m_CacheStats.UpstreamHitCount++;
}