[core] Check pending exception (#724)
This commit is contained in:
parent
9946708dbe
commit
0ad10cf369
|
|
@ -40,6 +40,7 @@ namespace art {
|
||||||
|
|
||||||
inline void
|
inline void
|
||||||
maybeSetTrusted(JNIEnv *env, jclass clazz, jobject class_loader, jobject j_cookie) {
|
maybeSetTrusted(JNIEnv *env, jclass clazz, jobject class_loader, jobject j_cookie) {
|
||||||
|
if (env->ExceptionCheck()) return;
|
||||||
static auto get_parent = env->GetMethodID(env->FindClass("java/lang/ClassLoader"),
|
static auto get_parent = env->GetMethodID(env->FindClass("java/lang/ClassLoader"),
|
||||||
"getParent", "()Ljava/lang/ClassLoader;");
|
"getParent", "()Ljava/lang/ClassLoader;");
|
||||||
for (auto current = lspd::Context::GetInstance()->GetCurrentClassLoader();
|
for (auto current = lspd::Context::GetInstance()->GetCurrentClassLoader();
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue