17 lines
349 B
C++
17 lines
349 B
C++
#include "ping_thread.hpp"
|
|
|
|
#include "connection.hpp"
|
|
#include "ircmsg.hpp"
|
|
#include "write_irc.hpp"
|
|
|
|
auto PingThread::start(Connection& connection) -> void
|
|
{
|
|
connection.sig_ircmsg.connect([&connection](auto cmd, auto& msg)
|
|
{
|
|
if (IrcCommand::PING == cmd)
|
|
{
|
|
send_pong(connection, msg.args[0]);
|
|
}
|
|
});
|
|
}
|