felix-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cziege...@apache.org
Subject svn commit: r1005343 - /felix/trunk/scrplugin/src/main/java/org/apache/felix/scrplugin/JavaClassDescriptorManager.java
Date Thu, 07 Oct 2010 07:18:01 GMT
Author: cziegeler
Date: Thu Oct  7 07:18:01 2010
New Revision: 1005343

URL: http://svn.apache.org/viewvc?rev=1005343&view=rev
Log:
FELIX-2615 : ArrayOutOfBoundsException occurs from maven scr plugin when an empty class is
present - applied patch from Tharindu Mathew

Modified:
    felix/trunk/scrplugin/src/main/java/org/apache/felix/scrplugin/JavaClassDescriptorManager.java

Modified: felix/trunk/scrplugin/src/main/java/org/apache/felix/scrplugin/JavaClassDescriptorManager.java
URL: http://svn.apache.org/viewvc/felix/trunk/scrplugin/src/main/java/org/apache/felix/scrplugin/JavaClassDescriptorManager.java?rev=1005343&r1=1005342&r2=1005343&view=diff
==============================================================================
--- felix/trunk/scrplugin/src/main/java/org/apache/felix/scrplugin/JavaClassDescriptorManager.java
(original)
+++ felix/trunk/scrplugin/src/main/java/org/apache/felix/scrplugin/JavaClassDescriptorManager.java
Thu Oct  7 07:18:01 2010
@@ -270,6 +270,10 @@ public abstract class JavaClassDescripto
         final List<JavaClass> classes = new ArrayList<JavaClass>();
         for ( int i = 0; i < sources.length; i++ )
         {
+            if (sources[i].getClasses() == null || sources[i].getClasses().length == 0)
+            {
+                continue;
+            }
             for ( int j = 0; j < sources[i].getClasses().length; j++ )
             {
                 final JavaClass clazz = sources[i].getClasses()[j];



Mime
View raw message