diff options
author | JackLivio <jack@livio.io> | 2017-09-29 10:27:23 -0400 |
---|---|---|
committer | JackLivio <jack@livio.io> | 2017-09-29 10:27:23 -0400 |
commit | bae43b7e233787146aa9bed8f046ab10193e1dfe (patch) | |
tree | d8bd3aaab4dfe970153d2580b54f4d8ff657d100 | |
parent | 5fd981e582b92930ecb04e25a766eafa022dcceb (diff) | |
download | sdl_core-bae43b7e233787146aa9bed8f046ab10193e1dfe.tar.gz |
Fix compilation warning #1789
Changes made in #1789 + compilation fix. Original author @shoamano83
4 files changed, 12 insertions, 9 deletions
diff --git a/src/appMain/main.cc b/src/appMain/main.cc index 58ab02b123..07b9cacb78 100644 --- a/src/appMain/main.cc +++ b/src/appMain/main.cc @@ -148,10 +148,12 @@ int32_t main(int32_t argc, char** argv) { // Check if no error values were read from config file if (profile_instance.ErrorOccured()) { +#ifdef ENABLE_LOG const std::string& error = profile_instance.ErrorDescription(); LOG4CXX_FATAL(logger_, error); FLUSH_LOGGER(); DEINIT_LOGGER(); +#endif exit(EXIT_FAILURE); } diff --git a/src/components/application_manager/src/application_manager_impl.cc b/src/components/application_manager/src/application_manager_impl.cc index 411813cc83..1d41388910 100644 --- a/src/components/application_manager/src/application_manager_impl.cc +++ b/src/components/application_manager/src/application_manager_impl.cc @@ -1611,11 +1611,11 @@ void ApplicationManagerImpl::SendMessageToMobile( (*message)[strings::params][strings::function_id].asUInt()); if (function_id == mobile_apis::FunctionID::RegisterAppInterfaceID && (*message)[strings::msg_params][strings::success].asBool()) { - const bool is_for_plugin = plugin_manager_.IsAppForPlugins(app); LOG4CXX_INFO(logger_, - "Registered app " << app->app_id() << " is " - << (is_for_plugin ? "" : "not ") - << "for plugins."); + "Registered app " + << app->app_id() << " is " + << (plugin_manager_.IsAppForPlugins(app) ? "" : "not ") + << "for plugins."); } #endif // SDL_REMOTE_CONTROL } else if (app) { diff --git a/src/components/application_manager/src/policies/policy_handler.cc b/src/components/application_manager/src/policies/policy_handler.cc index ad21f533a1..e6ebaf3b83 100644 --- a/src/components/application_manager/src/policies/policy_handler.cc +++ b/src/components/application_manager/src/policies/policy_handler.cc @@ -808,17 +808,17 @@ bool PolicyHandler::IsAppSuitableForPolicyUpdate( const Applications::value_type value) const { LOG4CXX_AUTO_TRACE(logger_); - const uint32_t app_id = value->app_id(); - if (!value->IsRegistered()) { LOG4CXX_DEBUG(logger_, - "Application " << app_id << " is not marked as registered."); + "Application " << value->app_id() + << " is not marked as registered."); return false; } LOG4CXX_DEBUG(logger_, - "Application " << app_id << " marked as registered." - "Checking its parameters."); + "Application " << value->app_id() + << " marked as registered." + "Checking its parameters."); DeviceParams device_params = GetDeviceParams( value->device(), diff --git a/src/components/policy/policy_regular/src/cache_manager.cc b/src/components/policy/policy_regular/src/cache_manager.cc index b395e4e04c..8b6b9a433e 100644 --- a/src/components/policy/policy_regular/src/cache_manager.cc +++ b/src/components/policy/policy_regular/src/cache_manager.cc @@ -36,6 +36,7 @@ #include <functional> #include <ctime> #include <cmath> +#include <sstream> #include "utils/file_system.h" #include "json/reader.h" |