OSDN Git Service
(root)
/
android-x86
/
frameworks-base.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
05284b6
)
HIDL: Check error value.
author
Steven Moreland
<smoreland@google.com>
Wed, 17 Jan 2018 21:26:35 +0000
(13:26 -0800)
committer
Steven Moreland
<smoreland@google.com>
Wed, 17 Jan 2018 21:26:35 +0000
(13:26 -0800)
HwParcel's verifySuccess method doesn't actually check
to see if the call succeeded.
Change-Id: Iaa99cbfd6f5f211facaa20c09c5e1dae8e2b8a7f
Fixes:
71813867
Test: boot walleye, hidl_test_java
core/jni/android_os_HwParcel.cpp
patch
|
blob
|
history
diff --git
a/core/jni/android_os_HwParcel.cpp
b/core/jni/android_os_HwParcel.cpp
index
9494fb8
..
061349a
100644
(file)
--- a/
core/jni/android_os_HwParcel.cpp
+++ b/
core/jni/android_os_HwParcel.cpp
@@
-391,6
+391,10
@@
static void JHwParcel_native_verifySuccess(JNIEnv *env, jobject thiz) {
Status status;
status_t err = ::android::hardware::readFromParcel(&status, *parcel);
signalExceptionForError(env, err);
+
+ if (!status.isOk()) {
+ signalExceptionForError(env, UNKNOWN_ERROR, true /* canThrowRemoteException */);
+ }
}
static void JHwParcel_native_release(