logging rework json/proto (#102)

* cleanup: remove ambiled device

as written at the forum this is no longer supported. All people should move to adalight. They just need to flash a new sketch.

* fix typo

* travis.ci

* travis: move to ubuntu 14.04

* script try

* add serialport

* update .json files

* .

* .

* .

* update travis

* fix

* typo

* fix

* .

* disable v4l2 on mac

* disable email notification

* update osx

* maybe fix

* .

* disable osx and rm v4l2

* try osx

* try fix

* travis update

* add oe systemd file

* Proto

* Json

* fix

* fix2

* fix3

* .

* typo

* update

* revert runtime error
This commit is contained in:
brindosch
2016-07-11 17:08:22 +02:00
committed by GitHub
parent 070a534262
commit c802505553
11 changed files with 44 additions and 29 deletions

View File

@@ -9,7 +9,8 @@ JsonServer::JsonServer(uint16_t port) :
QObject(),
_hyperion(Hyperion::getInstance()),
_server(),
_openConnections()
_openConnections(),
_log(Logger::getInstance("JSONSERVER"))
{
if (!_server.listen(QHostAddress::Any, port))
{
@@ -50,7 +51,7 @@ void JsonServer::newConnection()
if (socket != nullptr)
{
std::cout << "JSONSERVER INFO: New connection" << std::endl;
Debug(_log, "New connection");
JsonClientConnection * connection = new JsonClientConnection(socket, _hyperion);
_openConnections.insert(connection);
@@ -61,7 +62,7 @@ void JsonServer::newConnection()
void JsonServer::closedConnection(JsonClientConnection *connection)
{
std::cout << "JSONSERVER INFO: Connection closed" << std::endl;
Debug(_log, "Connection closed");
_openConnections.remove(connection);
// schedule to delete the connection object