Merge "Parcel marshall - disallow RPC Parcels" am: 609f7a65b3 am: 9d4906616a

Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/2148573

Change-Id: I59f9609e9c67389205875c785c1ded91848aef36
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
Steven Moreland
2022-07-07 21:30:40 +00:00
committed by Automerger Merge Worker

View File

@@ -549,6 +549,11 @@ static jbyteArray android_os_Parcel_marshall(JNIEnv* env, jclass clazz, jlong na
return NULL; return NULL;
} }
if (parcel->isForRpc()) {
jniThrowException(env, "java/lang/RuntimeException", "Tried to marshall an RPC Parcel.");
return NULL;
}
if (parcel->objectsCount()) if (parcel->objectsCount())
{ {
jniThrowException(env, "java/lang/RuntimeException", jniThrowException(env, "java/lang/RuntimeException",