Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Commit 00ecc39

Browse files
committed
[fuchsia] Add diagnostics directory to the remote dirs and ensure entry exists
This reverts commit 4312d37. Once https://fuchsia-review.googlesource.com/c/topaz/+/351729 lands, the diagnostics directory will be present, this would be safe to do and the roller won't be blocked again.
1 parent 4cc307c commit 00ecc39

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

shell/platform/fuchsia/flutter/component.cc

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -233,15 +233,17 @@ Application::Application(
233233
<< "): " << zx_status_get_string(status);
234234
return;
235235
}
236-
const char* other_dirs[] = {"debug", "ctrl"};
236+
const char* other_dirs[] = {"debug", "ctrl", "diagnostics"};
237237
// add other directories as RemoteDirs.
238238
for (auto& dir_str : other_dirs) {
239239
fidl::InterfaceHandle<fuchsia::io::Directory> dir;
240240
auto request = dir.NewRequest().TakeChannel();
241-
fdio_service_connect_at(directory_ptr_.channel().get(), dir_str,
242-
request.release());
243-
outgoing_dir_->AddEntry(
244-
dir_str, std::make_unique<vfs::RemoteDir>(dir.TakeChannel()));
241+
auto status = fdio_service_connect_at(directory_ptr_.channel().get(),
242+
dir_str, request.release());
243+
if (status == ZX_OK) {
244+
outgoing_dir_->AddEntry(
245+
dir_str, std::make_unique<vfs::RemoteDir>(dir.TakeChannel()));
246+
}
245247
}
246248
};
247249

0 commit comments

Comments
 (0)