Author: markt Date: Sun Jul 29 19:32:20 2012 New Revision: 1366914 URL: http://svn.apache.org/viewvc?rev=1366914&view=rev Log: FindBugs: Fix potential NPE
Modified: tomcat/tc7.0.x/trunk/ (props changed) tomcat/tc7.0.x/trunk/java/org/apache/catalina/tribes/io/ReplicationStream.java tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Propchange: tomcat/tc7.0.x/trunk/ ------------------------------------------------------------------------------ Merged /tomcat/trunk:r1366910 Modified: tomcat/tc7.0.x/trunk/java/org/apache/catalina/tribes/io/ReplicationStream.java URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/catalina/tribes/io/ReplicationStream.java?rev=1366914&r1=1366913&r2=1366914&view=diff ============================================================================== --- tomcat/tc7.0.x/trunk/java/org/apache/catalina/tribes/io/ReplicationStream.java (original) +++ tomcat/tc7.0.x/trunk/java/org/apache/catalina/tribes/io/ReplicationStream.java Sun Jul 29 19:32:20 2012 @@ -105,7 +105,12 @@ public final class ReplicationStream ext protected Class<?> resolveProxyClass(String[] interfaces) throws IOException, ClassNotFoundException { - ClassLoader latestLoader = (classLoaders!=null && classLoaders.length==0)?null:classLoaders[0]; + ClassLoader latestLoader; + if (classLoaders != null && classLoaders.length > 0) { + latestLoader = classLoaders[0]; + } else { + latestLoader = null; + } ClassLoader nonPublicLoader = null; boolean hasNonPublicInterface = false; Modified: tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml?rev=1366914&r1=1366913&r2=1366914&view=diff ============================================================================== --- tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml (original) +++ tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Sun Jul 29 19:32:20 2012 @@ -121,6 +121,14 @@ </fix> </changelog> </subsection> + <subsection name="Tribes"> + <changelog> + <fix> + Avoid potential NPE identified by Find Bugs in + <code>org.apache.catalina.tribes.io.ReplicationStream</code>. (markt) + </fix> + </changelog> + </subsection> </section> <section name="Tomcat 7.0.29 (markt)" rtext="released 2012-07-08"> <subsection name="Catalina"> --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org