Print step name when error occured 46/74946/1
authorSangyoon Jang <s89.jang@samsung.com>
Thu, 16 Jun 2016 06:40:43 +0000 (15:40 +0900)
committerSangyoon Jang <s89.jang@samsung.com>
Thu, 16 Jun 2016 06:40:43 +0000 (15:40 +0900)
Change-Id: Ib6afc89ebc38ac288555ce491774114d3728d8d2
Signed-off-by: Sangyoon Jang <s89.jang@samsung.com>
src/common/app_installer.cc

index ec5f84d..72173e4 100644 (file)
@@ -85,11 +85,12 @@ AppInstaller::Result AppInstaller::Run() {
   }
 
   if (it != itEnd) {
-    LOG(ERROR) << "Failure occurs";
+    LOG(ERROR) << "Failure occurs in step: " << (*it)->name();
     do {
       try {
         if ((*it)->undo() != Step::Status::OK) {
-          LOG(ERROR) << "Error during undo operation, but continuing...";
+          LOG(ERROR) << "Error during undo operation(" << (*it)->name()
+                     << "), but continuing...";
           ret = Result::UNDO_ERROR;
         }
       } catch (const std::exception& err) {
@@ -102,7 +103,7 @@ AppInstaller::Result AppInstaller::Run() {
     for (auto& step : steps_) {
       try {
         if (step->clean() != Step::Status::OK) {
-          LOG(ERROR) << "Error during clean operation";
+          LOG(ERROR) << "Error during clean operation(" << step->name() << ")";
           ret = Result::CLEANUP_ERROR;
           break;
         }