mirror of
https://github.com/ceph/ceph
synced 2025-03-11 02:39:05 +00:00
Merge pull request #18003 from cbodley/wip-build-options-move
common: use move instead of copy in build_options() Reviewed-by: Jos Collin <jcollin@redhat.com>
This commit is contained in:
commit
1d26eb38bf
@ -6053,10 +6053,9 @@ static std::vector<Option> build_options()
|
||||
std::vector<Option> result = get_global_options();
|
||||
|
||||
auto ingest = [&result](std::vector<Option>&& options, const char* svc) {
|
||||
for (const auto &o_in : options) {
|
||||
Option o(o_in);
|
||||
for (auto &o : options) {
|
||||
o.add_service(svc);
|
||||
result.push_back(o);
|
||||
result.push_back(std::move(o));
|
||||
}
|
||||
};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user