diff options
author | christian mueller <christian.ei.mueller@bmw.de> | 2012-01-30 18:38:07 +0100 |
---|---|---|
committer | christian mueller <christian.ei.mueller@bmw.de> | 2012-01-31 17:40:32 +0100 |
commit | ad0c452e9890a35a1b7a6c2e2421e092c5cf2c2d (patch) | |
tree | 48cc38fa0a4ada0ece0f8571260c5438b64a675c /AudioManagerDaemon/src/CommandSender.cpp | |
parent | 58d62c4af578c10375bf9baa946e33f340c42a1f (diff) | |
download | audiomanager-ad0c452e9890a35a1b7a6c2e2421e092c5cf2c2d.tar.gz |
* wrapping DLT calls in a new Class because of performance, codesize and lazyness reasons
* the whole project now compiles without a warning with -pedantic
Diffstat (limited to 'AudioManagerDaemon/src/CommandSender.cpp')
-rw-r--r-- | AudioManagerDaemon/src/CommandSender.cpp | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/AudioManagerDaemon/src/CommandSender.cpp b/AudioManagerDaemon/src/CommandSender.cpp index a02d3f8..7a5b75e 100644 --- a/AudioManagerDaemon/src/CommandSender.cpp +++ b/AudioManagerDaemon/src/CommandSender.cpp @@ -25,14 +25,12 @@ #include "CommandSender.h" #include "command/CommandReceiveInterface.h" #include <dirent.h> -#include <dlt/dlt.h> #include "PluginTemplate.h" +#include "DLTWrapper.h" using namespace am; #define REQUIRED_INTERFACE_VERSION 1 -DLT_IMPORT_CONTEXT(AudioManager) - //!< macro to call all interfaces #define CALL_ALL_INTERFACES(...) \ std::vector<CommandSendInterface*>::iterator iter = mListInterfaces.begin(); \ @@ -54,12 +52,12 @@ CommandSender::CommandSender(const std::vector<std::string>& listOfPluginDirecto for (; dirIter < dirIterEnd; ++dirIter) { const char* directoryName = dirIter->c_str(); - DLT_LOG(AudioManager, DLT_LOG_INFO, DLT_STRING("Searching for CommandPlugins in"), DLT_STRING(directoryName)); + logInfo("Searching for CommandPlugins in",directoryName); DIR *directory = opendir(directoryName); if (!directory) { - DLT_LOG(AudioManager, DLT_LOG_INFO, DLT_STRING("Error opening directory "), DLT_STRING(directoryName)); + logInfo("Error opening directory ",directoryName); continue; } @@ -88,14 +86,14 @@ CommandSender::CommandSender(const std::vector<std::string>& listOfPluginDirecto for (; iter < iterEnd; ++iter) { - DLT_LOG(AudioManager, DLT_LOG_INFO, DLT_STRING("Loading CommandSender plugin"), DLT_STRING(iter->c_str())); + logInfo("Loading CommandSender plugin",*iter); CommandSendInterface* (*createFunc)(); void* tempLibHandle = NULL; createFunc = getCreateFunction<CommandSendInterface*()>(*iter, tempLibHandle); if (!createFunc) { - DLT_LOG(AudioManager, DLT_LOG_INFO, DLT_STRING("Entry point of CommandPlugin not found"), DLT_STRING(iter->c_str())); + logInfo("Entry point of CommandPlugin not found",*iter); continue; } @@ -103,14 +101,14 @@ CommandSender::CommandSender(const std::vector<std::string>& listOfPluginDirecto if (!commander) { - DLT_LOG(AudioManager, DLT_LOG_INFO, DLT_STRING("CommandPlugin initialization failed. Entry Function not callable")); + logInfo("CommandPlugin initialization failed. Entry Function not callable"); continue; } //check libversion if (commander->getInterfaceVersion() < REQUIRED_INTERFACE_VERSION) { - DLT_LOG(AudioManager, DLT_LOG_INFO, DLT_STRING("RoutingPlugin initialization failed. Version of Interface to old")); + logInfo("RoutingPlugin initialization failed. Version of Interface to old"); continue; } |