mirror of
https://github.com/FairRootGroup/FairMQ.git
synced 2025-10-13 16:46:47 +00:00
FairMQChannel: avoid copy when iterating over endpoints
This commit is contained in:
parent
d03a504ccd
commit
120760da0a
|
@ -381,7 +381,7 @@ try {
|
||||||
} else {
|
} else {
|
||||||
vector<string> endpoints;
|
vector<string> endpoints;
|
||||||
boost::algorithm::split(endpoints, fAddress, boost::algorithm::is_any_of(";"));
|
boost::algorithm::split(endpoints, fAddress, boost::algorithm::is_any_of(";"));
|
||||||
for (const auto endpoint : endpoints) {
|
for (const auto& endpoint : endpoints) {
|
||||||
string address;
|
string address;
|
||||||
if (endpoint[0] == '@' || endpoint[0] == '+' || endpoint[0] == '>') {
|
if (endpoint[0] == '@' || endpoint[0] == '+' || endpoint[0] == '>') {
|
||||||
address = endpoint.substr(1);
|
address = endpoint.substr(1);
|
||||||
|
|
Loading…
Reference in New Issue
Block a user