1717package android .signature .cts ;
1818
1919import android .util .Log ;
20- import java . lang . reflect . Constructor ;
20+
2121import java .lang .reflect .Executable ;
2222import java .lang .reflect .Field ;
2323import java .lang .reflect .InvocationTargetException ;
@@ -97,8 +97,7 @@ public static void checkSingleMember(DexMember dexMember, boolean reflection, bo
9797 if (jni ) {
9898 try {
9999 observer .fieldAccessibleViaJni (hasMatchingField_JNI (klass , field ), field );
100- } catch (ClassNotFoundException | ExceptionInInitializerError | UnsatisfiedLinkError
101- | NoClassDefFoundError e ) {
100+ } catch (ClassNotFoundException | Error e ) {
102101 if ((e instanceof NoClassDefFoundError )
103102 && !(e .getCause () instanceof ExceptionInInitializerError )
104103 && !(e .getCause () instanceof UnsatisfiedLinkError )) {
@@ -122,11 +121,8 @@ public static void checkSingleMember(DexMember dexMember, boolean reflection, bo
122121 if (jni ) {
123122 try {
124123 observer .methodAccessibleViaJni (hasMatchingMethod_JNI (klass , method ), method );
125- } catch (ExceptionInInitializerError | UnsatisfiedLinkError
126- | NoClassDefFoundError e ) {
127- if ((e instanceof NoClassDefFoundError )
128- && !(e .getCause () instanceof ExceptionInInitializerError )
129- && !(e .getCause () instanceof UnsatisfiedLinkError )) {
124+ } catch (Error e ) {
125+ if ((e instanceof NoClassDefFoundError ) && !(e .getCause () instanceof Error )) {
130126 throw e ;
131127 }
132128
0 commit comments