Improve logging when source hash mismatches.
am: a3244d3686
Change-Id: I5462275772e93cb4b5c5fae2409ac8ef56b160cb
diff --git a/payload_consumer/delta_performer.cc b/payload_consumer/delta_performer.cc
index 3131a6e..6845b76 100644
--- a/payload_consumer/delta_performer.cc
+++ b/payload_consumer/delta_performer.cc
@@ -278,8 +278,13 @@
if (op_result)
return true;
+ size_t partition_first_op_num =
+ current_partition_ ? acc_num_operations_[current_partition_ - 1] : 0;
LOG(ERROR) << "Failed to perform " << op_type_name << " operation "
- << next_operation_num_;
+ << next_operation_num_ << ", which is the operation "
+ << next_operation_num_ - partition_first_op_num
+ << " in partition \""
+ << partitions_[current_partition_].partition_name() << "\"";
*error = ErrorCode::kDownloadOperationExecutionError;
return false;
}