From 0cedf6b2e95df05c6dfa8275a895c7fae18d1fe6 Mon Sep 17 00:00:00 2001 From: marazmista Date: Wed, 20 Feb 2019 21:39:54 +0100 Subject: [PATCH] added version, display it at start --- radeon-profile-daemon/rpdthread.cpp | 8 +++++--- radeon-profile-daemon/rpdthread.h | 2 +- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/radeon-profile-daemon/rpdthread.cpp b/radeon-profile-daemon/rpdthread.cpp index 29ad0d9..4b7ea1a 100644 --- a/radeon-profile-daemon/rpdthread.cpp +++ b/radeon-profile-daemon/rpdthread.cpp @@ -13,6 +13,7 @@ rpdThread::rpdThread() : QThread(), signalReceiver(nullptr), connectionConfirmed(false) { + qInfo() << "radeon-profile-daemon (v. " + appVersion + ")"; qDebug() << "Starting in debug mode"; createServer(); @@ -21,10 +22,11 @@ rpdThread::rpdThread() : QThread(), connectionCheckTimer.setInterval(20000); connect(&connectionCheckTimer, SIGNAL(timeout()), this, SLOT(checkConnection())); + } void rpdThread::newConn() { - qWarning() << "Connecting to the client"; + qInfo() << "Connecting to the client"; signalReceiver = daemonServer.nextPendingConnection(); connect(signalReceiver,SIGNAL(readyRead()),this,SLOT(decodeSignal())); connect(signalReceiver,SIGNAL(disconnected()),this,SLOT(disconnected())); @@ -41,7 +43,7 @@ void rpdThread::createServer() if (daemonServer.isListening()) return; - qDebug() << "Awaiting connections..."; + qInfo() << "Awaiting connections..."; QLocalServer::removeServer(serverName); daemonServer.listen(serverName); @@ -66,7 +68,7 @@ void rpdThread::closeConnection() } void rpdThread::disconnected() { - qWarning() << "Disconnecting from the client"; + qInfo() << "Client disconnected"; closeConnection(); } diff --git a/radeon-profile-daemon/rpdthread.h b/radeon-profile-daemon/rpdthread.h index 4782489..4b8ee4d 100644 --- a/radeon-profile-daemon/rpdthread.h +++ b/radeon-profile-daemon/rpdthread.h @@ -30,7 +30,7 @@ #define SIGNAL_SHAREDMEM_KEY '6' #define SIGNAL_ALIVE '7' - +const QString appVersion = "20190220"; const QString serverName = "radeon-profile-daemon-server"; class rpdThread : public QThread