diff options
| author | 2021-09-15 00:28:28 +0000 | |
|---|---|---|
| committer | 2021-09-15 00:28:28 +0000 | |
| commit | 31ae9afabd8087cd2b6cfe37fbab29b3630633c9 (patch) | |
| tree | 81f5f581a4a31201d90c1371b7a866182b7049c1 /libs/binder/ServiceManagerHost.cpp | |
| parent | 9b4ba33a6c3197af61df5eb919c9ed8f89125028 (diff) | |
| parent | 10b2b3884a975bde9765564f3fe6456c26c1c822 (diff) | |
Merge "Fix frameworks/native compiling against musl" am: 79abc0518e am: 06b1d1079f am: 31fab602aa am: 10b2b3884a
Original change: https://android-review.googlesource.com/c/platform/frameworks/native/+/1826713
Change-Id: I8c6ce9f67dc8fd6793f0ad55f88a5467e78dfb0b
Diffstat (limited to 'libs/binder/ServiceManagerHost.cpp')
| -rw-r--r-- | libs/binder/ServiceManagerHost.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/libs/binder/ServiceManagerHost.cpp b/libs/binder/ServiceManagerHost.cpp index 59334b7542..27cc563adc 100644 --- a/libs/binder/ServiceManagerHost.cpp +++ b/libs/binder/ServiceManagerHost.cpp @@ -74,12 +74,12 @@ std::optional<AdbForwarder> AdbForwarder::forward(unsigned int devicePort) { result->toString().c_str()); return std::nullopt; } - if (!result->stderr.empty()) { + if (!result->stderrStr.empty()) { LOG_HOST("`adb forward tcp:0 tcp:%d` writes to stderr: %s", devicePort, - result->stderr.c_str()); + result->stderrStr.c_str()); } - unsigned int hostPort = parsePortNumber(result->stdout, "host port"); + unsigned int hostPort = parsePortNumber(result->stdoutStr, "host port"); if (hostPort == 0) return std::nullopt; return AdbForwarder(hostPort); @@ -105,9 +105,9 @@ AdbForwarder::~AdbForwarder() { result->toString().c_str()); return; } - if (!result->stderr.empty()) { + if (!result->stderrStr.empty()) { LOG_HOST("`adb forward --remove tcp:%d` writes to stderr: %s", *mPort, - result->stderr.c_str()); + result->stderrStr.c_str()); } LOG_HOST("Successfully run `adb forward --remove tcp:%d`", *mPort); @@ -139,8 +139,8 @@ sp<IBinder> getDeviceService(std::vector<std::string>&& serviceDispatcherArgs) { ALOGE("Command exits with: %s", result->toString().c_str()); return nullptr; } - if (!result->stderr.empty()) { - LOG_HOST("servicedispatcher writes to stderr: %s", result->stderr.c_str()); + if (!result->stderrStr.empty()) { + LOG_HOST("servicedispatcher writes to stderr: %s", result->stderrStr.c_str()); } if (!result->stdoutEndsWithNewLine()) { @@ -148,7 +148,7 @@ sp<IBinder> getDeviceService(std::vector<std::string>&& serviceDispatcherArgs) { return nullptr; } - unsigned int devicePort = parsePortNumber(result->stdout, "device port"); + unsigned int devicePort = parsePortNumber(result->stdoutStr, "device port"); if (devicePort == 0) return nullptr; auto forwardResult = AdbForwarder::forward(devicePort); |