vm_tools: concierge: use AsyncNoReject for dlcservice calls.
crrev.com/c/2549481 neglected to enable the new async functionality for
the dlcservice queries.
This caused dlc-dependent VMs like borealis to no longer function.
BUG=b:175906849
TEST=`borealis start` on DUT after `emerge-hatch-borealis vm_host_tools`
Change-Id: Icd486b4e69ca963cd1d2b5afd8bafeb4effb12f0
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform2/+/2596662
Reviewed-by: Stephen Barber <smbarber@chromium.org>
Reviewed-by: Woody Chow <woodychow@google.com>
Reviewed-by: Chirantan Ekbote <chirantan@chromium.org>
Tested-by: Nic Hollingum <hollingum@google.com>
Commit-Queue: Nic Hollingum <hollingum@google.com>
diff --git a/vm_tools/concierge/service.cc b/vm_tools/concierge/service.cc
index 76fdbe3..b34dcdc 100644
--- a/vm_tools/concierge/service.cc
+++ b/vm_tools/concierge/service.cc
@@ -3415,7 +3415,16 @@
}
base::Optional<std::string> dlc_root =
- dlcservice_client_->GetRootPath(dlc_id, failure_reason);
+ AsyncNoReject(bus_->GetDBusTaskRunner(),
+ base::BindOnce(
+ [](DlcHelper* dlc_helper, const std::string& dlc_id,
+ std::string* out_failure_reason) {
+ return dlc_helper->GetRootPath(dlc_id,
+ out_failure_reason);
+ },
+ dlcservice_client_.get(), dlc_id, failure_reason))
+ .Get()
+ .val;
if (!dlc_root.has_value()) {
// On an error, failure_reason will be set by GetRootPath().
return {};