[frdp] Adds paths for find and ls for Fuchsia execution. (#26680)

Adds full path for `find` and `ls` commands.
This commit is contained in:
Andrew Davies
2019-01-22 10:49:17 -08:00
committed by GitHub
parent f777db2b78
commit 33cd720db6
2 changed files with 10 additions and 7 deletions

View File

@@ -523,14 +523,15 @@ class FuchsiaRemoteConnection {
/// found. An exception is thrown in the event of an actual error when
/// attempting to acquire the ports.
Future<List<int>> getDeviceServicePorts() async {
final List<String> portPaths =
await _sshCommandRunner.run('find /hub -name vmservice-port');
final List<String> portPaths = await _sshCommandRunner
.run('/system/bin/find /hub -name vmservice-port');
final List<int> ports = <int>[];
for (String path in portPaths) {
if (path == '') {
continue;
}
final List<String> lsOutput = await _sshCommandRunner.run('ls $path');
final List<String> lsOutput =
await _sshCommandRunner.run('/system/bin/ls $path');
for (String line in lsOutput) {
if (line == '') {
continue;