Replace usage of base::Callback with std::function
Test: th
Change-Id: If1083578a78d33b0d149cce312dd36fc7ba5d8ce
diff --git a/aosp/update_engine_client_android.cc b/aosp/update_engine_client_android.cc
index c00e9f5..81736a7 100644
--- a/aosp/update_engine_client_android.cc
+++ b/aosp/update_engine_client_android.cc
@@ -117,8 +117,7 @@
android::BinderWrapper::Create();
android::BinderWrapper::Get()->RegisterForDeathNotifications(
android::os::IUpdateEngine::asBinder(service_),
- base::Bind(&UpdateEngineClientAndroid::UpdateEngineServiceDied,
- base::Unretained(this)));
+ [this]() { UpdateEngineServiceDied(); });
}
int UpdateEngineClientAndroid::OnInit() {
@@ -207,7 +206,7 @@
if (FLAGS_follow) {
// Register a callback object with the service.
callback_ = new UECallback(this);
- bool bound;
+ bool bound = false;
if (!service_->bind(callback_, &bound).isOk() || !bound) {
LOG(ERROR) << "Failed to bind() the UpdateEngine daemon.";
return 1;