--- smsdaemon/SmsDaemon.cpp 2008/12/06 15:13:34 128 +++ smsdaemon/SmsDaemon.cpp 2008/12/08 10:42:04 151 @@ -3,9 +3,11 @@ #include #include +#include + #include "common.h" -#include "GsmModem.h" +#include "ISmsTransceiver.h" #include "Plugin.h" #include "kbhit.h" @@ -14,6 +16,7 @@ #include "TaskManager.h" #include "PluginManager.h" +#include "ConfigFile.h" #include "version.h" @@ -22,7 +25,7 @@ void SmsDaemon::CreateLogMessage(SMS& sms,bool hasPlugin) { ostringstream os; - os << "Recieved sms from " << sms.sender << " ; command=" << GetSmsCommand(sms); + os << "Recieved sms from " << sms.GetSender() << " ; command=" << sms.ExtractCommand(); if (!hasPlugin) os << " -- PLUGIN NOT FOUND"; @@ -47,7 +50,7 @@ for (unsigned int i=0; ismsCounter.incomming++; } } @@ -96,7 +99,9 @@ void SmsDaemon::Start() { Common* cmn = Common::instance(); + string transceiver = cmn->GetConfigfile()->GetValue("smsdaemon","transceiver"); + srand(time(0)); cmn->daemonStart = time(0); _lastSmsCheck = Util::GetTimeOfDay(); @@ -104,6 +109,7 @@ cmn->logMessage("--------------------------------"); cmn->logMessage( VERSION ); cmn->logMessage( SVNVERSION ); + cmn->logMessage( string("Transceiver: ") + transceiver ); cmn->GetTaskManager()->LoadTasks(); cmn->GetPluginManager()->LoadPlugins();