summaryrefslogtreecommitdiffstats
path: root/searchsummary
diff options
context:
space:
mode:
authorHenning Baldersheim <balder@yahoo-inc.com>2023-03-07 11:00:25 +0000
committerHenning Baldersheim <balder@yahoo-inc.com>2023-03-07 11:00:25 +0000
commite2c778f1f53b8f60e6bd0b5260ce672e8bd1a062 (patch)
tree8fe9ce9d235be532d35fa2a9f80313d697bca103 /searchsummary
parentb886fb88c16da7f9577fdae175143c1923610fac (diff)
Add unit test for string attribute get_raw
Diffstat (limited to 'searchsummary')
-rw-r--r--searchsummary/src/vespa/searchsummary/docsummary/attributedfw.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/searchsummary/src/vespa/searchsummary/docsummary/attributedfw.cpp b/searchsummary/src/vespa/searchsummary/docsummary/attributedfw.cpp
index 74d67aabe88..e606c6f08bb 100644
--- a/searchsummary/src/vespa/searchsummary/docsummary/attributedfw.cpp
+++ b/searchsummary/src/vespa/searchsummary/docsummary/attributedfw.cpp
@@ -97,8 +97,8 @@ SingleAttrDFW::insertField(uint32_t docid, GetDocsumsState& state, Inserter &tar
break;
}
case BasicType::STRING: {
- const char *s = v.getString(docid, nullptr, 0); // no need to pass in a buffer, this attribute has a string storage.
- target.insertString(vespalib::Memory(s));
+ auto s = v.get_raw(docid);
+ target.insertString(vespalib::Memory(s.data(), s.size()));
break;
}
case BasicType::REFERENCE: