mirror of
https://github.com/gnss-sdr/gnss-sdr
synced 2024-12-15 04:30:33 +00:00
clang-tidy: apply performance-for-range-copy check
See https://clang.llvm.org/extra/clang-tidy/checks/performance-for-range-copy.html
This commit is contained in:
parent
eae967ed1a
commit
5b50e74ca8
@ -36,7 +36,7 @@
|
|||||||
|
|
||||||
Monitor_Pvt_Udp_Sink::Monitor_Pvt_Udp_Sink(const std::vector<std::string>& addresses, const uint16_t& port) : socket{io_service}
|
Monitor_Pvt_Udp_Sink::Monitor_Pvt_Udp_Sink(const std::vector<std::string>& addresses, const uint16_t& port) : socket{io_service}
|
||||||
{
|
{
|
||||||
for (auto address : addresses)
|
for (const auto& address : addresses)
|
||||||
{
|
{
|
||||||
boost::asio::ip::udp::endpoint endpoint(boost::asio::ip::address::from_string(address, error), port);
|
boost::asio::ip::udp::endpoint endpoint(boost::asio::ip::address::from_string(address, error), port);
|
||||||
endpoints.push_back(endpoint);
|
endpoints.push_back(endpoint);
|
||||||
@ -50,7 +50,7 @@ bool Monitor_Pvt_Udp_Sink::write_monitor_pvt(Monitor_Pvt monitor_pvt)
|
|||||||
oa << monitor_pvt;
|
oa << monitor_pvt;
|
||||||
std::string outbound_data = archive_stream.str();
|
std::string outbound_data = archive_stream.str();
|
||||||
|
|
||||||
for (auto endpoint : endpoints)
|
for (const auto& endpoint : endpoints)
|
||||||
{
|
{
|
||||||
socket.open(endpoint.protocol(), error);
|
socket.open(endpoint.protocol(), error);
|
||||||
socket.connect(endpoint, error);
|
socket.connect(endpoint, error);
|
||||||
|
@ -629,7 +629,7 @@ private:
|
|||||||
recent_msgs_.pop_front();
|
recent_msgs_.pop_front();
|
||||||
}
|
}
|
||||||
|
|
||||||
for (auto participant : participants_)
|
for (const auto& participant : participants_)
|
||||||
{
|
{
|
||||||
participant->deliver(msg);
|
participant->deliver(msg);
|
||||||
}
|
}
|
||||||
|
@ -37,7 +37,7 @@
|
|||||||
|
|
||||||
Gnss_Synchro_Udp_Sink::Gnss_Synchro_Udp_Sink(const std::vector<std::string>& addresses, const uint16_t& port) : socket{io_service}
|
Gnss_Synchro_Udp_Sink::Gnss_Synchro_Udp_Sink(const std::vector<std::string>& addresses, const uint16_t& port) : socket{io_service}
|
||||||
{
|
{
|
||||||
for (auto address : addresses)
|
for (const auto& address : addresses)
|
||||||
{
|
{
|
||||||
boost::asio::ip::udp::endpoint endpoint(boost::asio::ip::address::from_string(address, error), port);
|
boost::asio::ip::udp::endpoint endpoint(boost::asio::ip::address::from_string(address, error), port);
|
||||||
endpoints.push_back(endpoint);
|
endpoints.push_back(endpoint);
|
||||||
@ -51,7 +51,7 @@ bool Gnss_Synchro_Udp_Sink::write_gnss_synchro(const std::vector<Gnss_Synchro>&
|
|||||||
oa << stocks;
|
oa << stocks;
|
||||||
std::string outbound_data = archive_stream.str();
|
std::string outbound_data = archive_stream.str();
|
||||||
|
|
||||||
for (auto endpoint : endpoints)
|
for (const auto& endpoint : endpoints)
|
||||||
{
|
{
|
||||||
socket.open(endpoint.protocol(), error);
|
socket.open(endpoint.protocol(), error);
|
||||||
socket.connect(endpoint, error);
|
socket.connect(endpoint, error);
|
||||||
|
Loading…
Reference in New Issue
Block a user