am 708b42e0: am eba7afcc: am 2f340be3: Disregard alleged binder entities beyond parcel bounds
* commit '708b42e0ee5ad97b8426a6245f73131ddfc59a33':
Disregard alleged binder entities beyond parcel bounds
diff --git a/libs/binder/Parcel.cpp b/libs/binder/Parcel.cpp
index b2a4aae..d769caa 100644
--- a/libs/binder/Parcel.cpp
+++ b/libs/binder/Parcel.cpp
@@ -411,7 +411,7 @@
// Count objects in range
for (int i = 0; i < (int) size; i++) {
size_t off = objects[i];
- if ((off >= offset) && (off < offset + len)) {
+ if ((off >= offset) && (off + sizeof(flat_binder_object) <= offset + len)) {
if (firstIndex == -1) {
firstIndex = i;
}