From 89264dcafd21988f596a4bbdbb888fac41855445 Mon Sep 17 00:00:00 2001 From: Tomasz Iwanek Date: Mon, 12 Sep 2016 10:25:28 +0200 Subject: [PATCH] Buildbreak fix Change-Id: Id966e9f9b2c75ea572c8c8184afc329dfd134053 --- src/wgt/step/configuration/step_check_start_files.cc | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/src/wgt/step/configuration/step_check_start_files.cc b/src/wgt/step/configuration/step_check_start_files.cc index 7bf3ad6..6db5b8e 100644 --- a/src/wgt/step/configuration/step_check_start_files.cc +++ b/src/wgt/step/configuration/step_check_start_files.cc @@ -23,17 +23,21 @@ namespace configuration { common_installer::Step::Status StepCheckStartFiles::process() { bool flag = false; // it's not important in this step to use this flag std::string error; - bool result_check = CheckStartFile(static_cast - (context_->backend_data.get())->content.get(), - context_->unpacked_dir_path.get(), - &flag); + auto backend_data = + static_cast(context_->backend_data.get()); + auto content = std::make_shared(); + if (!backend_data->content.get().src().empty()) { + content.reset(new parse::ContentInfo(backend_data->content.get())); + } + + bool result_check = CheckStartFile(content, context_->unpacked_dir_path.get(), + &flag); if (!result_check) { LOG(ERROR) << "Could not find valid start file"; return common_installer::Step::Status::PARSE_ERROR; } - result_check = CheckServicesStartFiles(static_cast( - context_->backend_data.get())->service_list.get(), + result_check = CheckServicesStartFiles(backend_data->service_list.get(), context_->unpacked_dir_path.get(), &error); if (!result_check) { -- 2.7.4