summaryrefslogtreecommitdiff
path: root/src/components/application_manager/src/commands/mobile/set_icon_request.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/components/application_manager/src/commands/mobile/set_icon_request.cc')
-rw-r--r--src/components/application_manager/src/commands/mobile/set_icon_request.cc9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/components/application_manager/src/commands/mobile/set_icon_request.cc b/src/components/application_manager/src/commands/mobile/set_icon_request.cc
index 4b06730752..248367e9b3 100644
--- a/src/components/application_manager/src/commands/mobile/set_icon_request.cc
+++ b/src/components/application_manager/src/commands/mobile/set_icon_request.cc
@@ -51,7 +51,7 @@ SetIconRequest::~SetIconRequest() {
}
void SetIconRequest::Run() {
- LOG4CXX_INFO(logger_, "SetIconRequest::Run");
+ LOG4CXX_AUTO_TRACE(logger_);
ApplicationSharedPtr app =
ApplicationManagerImpl::instance()->application(connection_key());
@@ -102,7 +102,7 @@ void SetIconRequest::Run() {
}
void SetIconRequest::on_event(const event_engine::Event& event) {
- LOG4CXX_INFO(logger_, "SetIconRequest::on_event");
+ LOG4CXX_AUTO_TRACE(logger_);
const smart_objects::SmartObject& message = event.smart_object();
switch (event.id()) {
@@ -117,6 +117,11 @@ void SetIconRequest::on_event(const event_engine::Event& event) {
ApplicationSharedPtr app =
ApplicationManagerImpl::instance()->application(connection_key());
+ if (!message_.valid() || !app.valid()) {
+ LOG4CXX_ERROR(logger_, "NULL pointer.");
+ return;
+ }
+
const std::string path = (*message_)[strings::msg_params]
[strings::sync_file_name]
[strings::value].asString();