From 555923c40b49f6ce2b0ffb7220fe4be16a71cdbc Mon Sep 17 00:00:00 2001 From: Andreas Beeker Date: Tue, 24 Jul 2018 22:57:18 +0000 Subject: #62564 - replace Thread.currentThread().getContextClassLoader() with getClass().getClassLoader() git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1836590 13f79535-47bb-0310-9956-ffa450edef68 --- src/resources/devtools/forbidden-signatures.txt | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/resources') diff --git a/src/resources/devtools/forbidden-signatures.txt b/src/resources/devtools/forbidden-signatures.txt index 2ea708740c..e64d7e02cf 100644 --- a/src/resources/devtools/forbidden-signatures.txt +++ b/src/resources/devtools/forbidden-signatures.txt @@ -79,8 +79,9 @@ java.net.InetAddress#getCanonicalHostName() java.net.InetSocketAddress#getHostName() @ Use getHostString() instead, which avoids a DNS lookup -@defaultMessage this method needs special permission -java.lang.Thread#getAllStackTraces() + +java.lang.Thread#getAllStackTraces() @ this method needs special permission +java.lang.Thread#getContextClassLoader() @ use getClass().getClassLoader() instead of getContextClassLoader() (see https://stackoverflow.com/a/36228195/2066598) @defaultMessage Avoid unchecked warnings by using Collections#empty(List|Map|Set) methods java.util.Collections#EMPTY_LIST -- cgit v1.2.3