mirror of
https://gitee.com/milvus-io/milvus.git
synced 2026-01-07 19:31:51 +08:00
master https://github.com/milvus-io/milvus/pull/43183 fix: https://github.com/milvus-io/milvus/issues/43182 --------- Signed-off-by: SpadeA <tangchenjie1210@gmail.com>
This commit is contained in:
parent
8ac3adcc52
commit
6ccf1aa9b8
@ -90,6 +90,13 @@ class Json {
|
||||
cap);
|
||||
}
|
||||
|
||||
// WARN: this is used for fast non-copy construction,
|
||||
// MUST make sure there at least SIMDJSON_PADDING bytes allocated
|
||||
// after the string_view.
|
||||
explicit Json(const std::string_view& data)
|
||||
: Json(data.data(), data.size()) {
|
||||
}
|
||||
|
||||
// WARN: this is used for fast non-copy construction,
|
||||
// MUST make sure that the data points to a memory that
|
||||
// with size at least len + SIMDJSON_PADDING
|
||||
|
||||
@ -183,7 +183,7 @@ class SegmentInternalInterface : public SegmentInterface {
|
||||
std::vector<Json> res;
|
||||
res.reserve(string_views.size());
|
||||
for (const auto& str_view : string_views) {
|
||||
res.emplace_back(str_view);
|
||||
res.emplace_back(Json(str_view));
|
||||
}
|
||||
return {std::move(res), std::move(valid_data)};
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user