Skip to content

Luki42/lang-587

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Lang 587

Exception:

testToClass_object(org.apache.commons.lang3.ClassUtilsTest)  Time elapsed: 0.016 sec  <<< ERROR!
java.lang.NullPointerException: null
        at org.apache.commons.lang3.ClassUtils.toClass(ClassUtils.java:910)
        at org.apache.commons.lang3.ClassUtilsTest.testToClass_object(ClassUtilsTest.java:901)

Fix Commit: SVN Revision 907102

The test has been modified: the assertEquals(Arrays.equals(...)) (equivalent to assertArrayEquals) has been removed.

Patch: http://svn.apache.org/viewvc/commons/proper/lang/trunk/src/main/java/org/apache/commons/lang3/ClassUtils.java?r1=907102&r2=907101&pathrev=907102

Class<?>[] classes = new Class[array.length];
for (int i = 0; i < array.length; i++) {
-            classes[i] = array[i].getClass();
+            classes[i] = array[i] == null ? null : array[i].getClass();
}
return classes;

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published