|
@@ -55,7 +55,7 @@ public:
|
|
|
|
|
|
void boardcast(const std::vector<char>&msg)
|
|
void boardcast(const std::vector<char>&msg)
|
|
{
|
|
{
|
|
- for(auto&i:m_thread_clts)
|
|
|
|
|
|
+ for(const auto&i:m_thread_clts)
|
|
{
|
|
{
|
|
std::vector<char> tmp(msg);
|
|
std::vector<char> tmp(msg);
|
|
i->send(std::move(tmp));
|
|
i->send(std::move(tmp));
|
|
@@ -99,7 +99,7 @@ public:
|
|
|
|
|
|
void close_all()
|
|
void close_all()
|
|
{
|
|
{
|
|
- for(auto&clt:m_thread_clts)
|
|
|
|
|
|
+ for(const auto&clt:m_thread_clts)
|
|
{
|
|
{
|
|
if(!clt)
|
|
if(!clt)
|
|
continue;
|
|
continue;
|
|
@@ -110,7 +110,7 @@ public:
|
|
|
|
|
|
void on_async(const std::list<std::shared_ptr<client>>¬ify_clts)
|
|
void on_async(const std::list<std::shared_ptr<client>>¬ify_clts)
|
|
{
|
|
{
|
|
- for(auto&clt:notify_clts)
|
|
|
|
|
|
+ for(const auto&clt:notify_clts)
|
|
{
|
|
{
|
|
((client_ex*)clt.get())->on_notify();
|
|
((client_ex*)clt.get())->on_notify();
|
|
}
|
|
}
|