mirror of
https://github.com/badaix/snapcast.git
synced 2025-07-22 02:47:50 +02:00
basic telnet like control server
This commit is contained in:
parent
635daabd8c
commit
504884feb9
14 changed files with 7887 additions and 119 deletions
|
@ -23,6 +23,7 @@
|
|||
#include "clientConnection.h"
|
||||
#include "common/utils.h"
|
||||
#include "common/snapException.h"
|
||||
#include "message/hello.h"
|
||||
|
||||
|
||||
using namespace std;
|
||||
|
@ -69,7 +70,10 @@ void ClientConnection::start()
|
|||
// setsockopt(socket->native(), SOL_SOCKET, SO_RCVTIMEO, &tv, sizeof(tv));
|
||||
// setsockopt(socket->native(), SOL_SOCKET, SO_SNDTIMEO, &tv, sizeof(tv));
|
||||
socket_->connect(*iterator);
|
||||
|
||||
logO << "My MAC: \"" << getMacAddress(socket_->native()) << "\"\n";
|
||||
msg::Hello hello(getMacAddress(socket_->native()));
|
||||
send(&hello);
|
||||
connected_ = true;
|
||||
logS(kLogNotice) << "Connected to " << socket_->remote_endpoint().address().to_string() << endl;
|
||||
active_ = true;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue