logger: Fixing the bug with redirecting of log output to the standard error

Change-Id: I4f84548643a4ea3b0b1ef8f341e39d01e90eb55b
diff --git a/src/logger.cpp b/src/logger.cpp
index e4f5b9b..6d89450 100644
--- a/src/logger.cpp
+++ b/src/logger.cpp
@@ -45,8 +45,7 @@
   }
   else {
     PatternLayoutPtr   layout(new PatternLayout("%d{HH:mm:ss} %p %c{1} - %m%n"));
-    ConsoleAppenderPtr appender(new ConsoleAppender(layout));
-    appender->setTarget("System.cerr");
+    ConsoleAppenderPtr appender(new ConsoleAppender(layout, ConsoleAppender::getSystemErr()));
     BasicConfigurator::configure(appender);
     Logger::getRootLogger()->setLevel(log4cxx::Level::getInfo());
   }