summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--document/src/vespa/document/fieldvalue/structfieldvalue.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/document/src/vespa/document/fieldvalue/structfieldvalue.cpp b/document/src/vespa/document/fieldvalue/structfieldvalue.cpp
index 703650f7325..793f6918bd1 100644
--- a/document/src/vespa/document/fieldvalue/structfieldvalue.cpp
+++ b/document/src/vespa/document/fieldvalue/structfieldvalue.cpp
@@ -182,8 +182,8 @@ StructFieldValue::getFieldValue(const Field& field, FieldValue& value) const
if (buf.size() > 0) {
nbostream_longlivedbuf stream(buf.c_str(), buf.size());
if ((_repo == nullptr) && (_doc_type != nullptr)) {
- std::unique_ptr<const DocumentTypeRepo> tmpRepo(new DocumentTypeRepo(*_doc_type));
- createFV(value, *tmpRepo, stream, *_doc_type, _version);
+ DocumentTypeRepo tmpRepo(*_doc_type);
+ createFV(value, tmpRepo, stream, *_doc_type, _version);
} else {
createFV(value, *_repo, stream, *_doc_type, _version);
}