aboutsummaryrefslogtreecommitdiff
path: root/zenhttp/httpshared.cpp
diff options
context:
space:
mode:
authorStefan Boberg <[email protected]>2022-06-10 16:17:18 +0200
committerStefan Boberg <[email protected]>2022-06-10 16:17:18 +0200
commita203814b85c5ed5f1846d5efe1d26102775e44a2 (patch)
tree0e7d2c1413f00b00aefe0ec78e407697592fcc43 /zenhttp/httpshared.cpp
parentMerge branch 'main' of https://github.com/EpicGames/zen (diff)
downloadzen-a203814b85c5ed5f1846d5efe1d26102775e44a2.tar.xz
zen-a203814b85c5ed5f1846d5efe1d26102775e44a2.zip
fixed issue in CbPackage marshaling of local references
Diffstat (limited to 'zenhttp/httpshared.cpp')
-rw-r--r--zenhttp/httpshared.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/zenhttp/httpshared.cpp b/zenhttp/httpshared.cpp
index 7b92a0587..8149adbaf 100644
--- a/zenhttp/httpshared.cpp
+++ b/zenhttp/httpshared.cpp
@@ -407,7 +407,9 @@ CbPackageReader::MarshalLocalChunkReference(IoBuffer AttachmentBuffer)
ZEN_ASSERT(AttachmentBuffer.Size() >= (sizeof(CbAttachmentReferenceHeader) + AttachRefHdr->AbsolutePathLength));
- std::filesystem::path Path{PathPointer};
+ std::u8string_view PathView{PathPointer, AttachRefHdr->AbsolutePathLength};
+
+ std::filesystem::path Path{PathView};
IoBuffer ChunkReference = IoBufferBuilder::MakeFromFile(Path, AttachRefHdr->PayloadByteOffset, AttachRefHdr->PayloadByteSize);