summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Treehugger Robot <treehugger-gerrit@google.com> 2022-08-04 00:14:17 +0000
committer Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com> 2022-08-04 00:14:17 +0000
commitf9323e22ab5b78ab37a4a39865061f5b2cf5f2e7 (patch)
treef0d878260b21ba7de970bcc1dfa6d9820e7f816e
parent29bfcc3386249e173bccb0700c97399666ed222d (diff)
parent7df21869ed556179269a7bd57fd58bca6b16a44b (diff)
Merge "libbinder: fix type of return value from {send,read}_msg" am: 2a2071242b am: dcbef39392 am: 2300724f7a am: adf1262275 am: 7df21869ed
Original change: https://android-review.googlesource.com/c/platform/frameworks/native/+/2173482 Change-Id: Ib45ab390743fe6efead78c1339b4051fee7dac76 Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
-rw-r--r--libs/binder/trusty/RpcTransportTipcTrusty.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/libs/binder/trusty/RpcTransportTipcTrusty.cpp b/libs/binder/trusty/RpcTransportTipcTrusty.cpp
index e0d80fbe7b..dc27eb929c 100644
--- a/libs/binder/trusty/RpcTransportTipcTrusty.cpp
+++ b/libs/binder/trusty/RpcTransportTipcTrusty.cpp
@@ -64,7 +64,7 @@ public:
.num_handles = 0, // TODO: add ancillaryFds
.handles = nullptr,
};
- int rc = send_msg(mSocket.get(), &msg);
+ ssize_t rc = send_msg(mSocket.get(), &msg);
if (rc == ERR_NOT_ENOUGH_BUFFER) {
// Peer is blocked, wait until it unblocks.
// TODO: when tipc supports a send-unblocked handler,
@@ -89,7 +89,7 @@ public:
return statusFromTrusty(rc);
}
LOG_ALWAYS_FATAL_IF(static_cast<size_t>(rc) != size,
- "Sent the wrong number of bytes %d!=%zu", rc, size);
+ "Sent the wrong number of bytes %zd!=%zu", rc, size);
return OK;
}
@@ -129,7 +129,7 @@ public:
.num_handles = 0, // TODO: support ancillaryFds
.handles = nullptr,
};
- int rc = read_msg(mSocket.get(), mMessageInfo.id, mMessageOffset, &msg);
+ ssize_t rc = read_msg(mSocket.get(), mMessageInfo.id, mMessageOffset, &msg);
if (rc < 0) {
return statusFromTrusty(rc);
}