From 7a2f642bae27f940b7a68753c3fbad700af2267f Mon Sep 17 00:00:00 2001 From: Steven Moreland Date: Thu, 7 Jul 2022 16:45:18 +0000 Subject: [PATCH] Parcel marshall error explain objects A kernel binder object for libbinder can either be a binder object or an FD. Bug: N/A (from email thread) Test: N/A Change-Id: Iaa02595c5859879749f776222eccca52e782cbfb --- core/jni/android_os_Parcel.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/jni/android_os_Parcel.cpp b/core/jni/android_os_Parcel.cpp index 0d530f6aa2bb3..acadac78ce135 100644 --- a/core/jni/android_os_Parcel.cpp +++ b/core/jni/android_os_Parcel.cpp @@ -549,10 +549,10 @@ static jbyteArray android_os_Parcel_marshall(JNIEnv* env, jclass clazz, jlong na return NULL; } - // do not marshall if there are binder objects in the parcel if (parcel->objectsCount()) { - jniThrowException(env, "java/lang/RuntimeException", "Tried to marshall a Parcel that contained Binder objects."); + jniThrowException(env, "java/lang/RuntimeException", + "Tried to marshall a Parcel that contains objects (binders or FDs)."); return NULL; }