Merge "Fix error formatting issues" am: cd95e9fa3b
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1707886 Change-Id: I4fdf71f667af2ab6f2276d53b210a892e1fca912
This commit is contained in:
@@ -402,7 +402,7 @@ jboolean com_android_internal_os_ZygoteCommandBuffer_nativeForkRepeatedly(
|
|||||||
socklen_t cred_size = sizeof credentials;
|
socklen_t cred_size = sizeof credentials;
|
||||||
if (getsockopt(n_buffer->getFd(), SOL_SOCKET, SO_PEERCRED, &credentials, &cred_size) == -1
|
if (getsockopt(n_buffer->getFd(), SOL_SOCKET, SO_PEERCRED, &credentials, &cred_size) == -1
|
||||||
|| cred_size != sizeof credentials) {
|
|| cred_size != sizeof credentials) {
|
||||||
fail_fn_1("ForkMany failed to get initial credentials, %s", strerror(errno));
|
fail_fn_1(CREATE_ERROR("ForkMany failed to get initial credentials, %s", strerror(errno)));
|
||||||
}
|
}
|
||||||
|
|
||||||
bool first_time = true;
|
bool first_time = true;
|
||||||
@@ -453,7 +453,7 @@ jboolean com_android_internal_os_ZygoteCommandBuffer_nativeForkRepeatedly(
|
|||||||
close(session_socket);
|
close(session_socket);
|
||||||
int new_fd = accept(zygote_socket_fd, nullptr, nullptr);
|
int new_fd = accept(zygote_socket_fd, nullptr, nullptr);
|
||||||
if (new_fd == -1) {
|
if (new_fd == -1) {
|
||||||
fail_fn_z("Accept(%d) failed: %s", zygote_socket_fd, strerror(errno));
|
fail_fn_z(CREATE_ERROR("Accept(%d) failed: %s", zygote_socket_fd, strerror(errno)));
|
||||||
}
|
}
|
||||||
if (new_fd != session_socket) {
|
if (new_fd != session_socket) {
|
||||||
// Move new_fd back to the old value, so that we don't have to change Java-level data
|
// Move new_fd back to the old value, so that we don't have to change Java-level data
|
||||||
|
|||||||
Reference in New Issue
Block a user