Merge branch '6.0.x'

This commit is contained in:
Juergen Hoeller
2023-08-16 12:48:43 +02:00
4 changed files with 37 additions and 32 deletions

View File

@@ -1309,8 +1309,8 @@ public abstract class AnnotationUtils {
*/
public static boolean isSynthesizedAnnotation(@Nullable Annotation annotation) {
try {
return ((annotation != null) && Proxy.isProxyClass(annotation.getClass()) &&
(Proxy.getInvocationHandler(annotation) instanceof SynthesizedMergedAnnotationInvocationHandler));
return (annotation != null && Proxy.isProxyClass(annotation.getClass()) &&
Proxy.getInvocationHandler(annotation) instanceof SynthesizedMergedAnnotationInvocationHandler);
}
catch (SecurityException ex) {
// Security settings disallow reflective access to the InvocationHandler: