#vulnerable code 
                                private void collectLibraryInputFiles()
    {
        if ( parsedIncludeJdkLibs )
        {
            final String slash = File.separator;
            // we have to add the Java framework classes to the library JARs, since they are not
            // distributed with the JAR on Central, and since we'll strip them out of the android.jar
            // that is shipped with the SDK (since that is not a complete Java distribution)
            String javaHome = System.getProperty( "java.home" );
            String jdkLibsPath = null;
            if ( javaHome.startsWith( "/System/Library/Java" ) || javaHome.startsWith( "/Library/Java" ) )
            {
                // MacOS X uses different naming conventions for JDK installations
                jdkLibsPath = javaHome + "/../Classes";
                addLibraryJar( jdkLibsPath + "/classes.jar" );
            }
            else
            {
                jdkLibsPath = javaHome + slash + "lib";
                addLibraryJar( jdkLibsPath + slash + "rt.jar" );
            }
            // we also need to add the JAR containing e.g. javax.servlet
            addLibraryJar( jdkLibsPath + slash + "jsse.jar" );
            // and the javax.crypto stuff
            addLibraryJar( jdkLibsPath + slash + "jce.jar" );
        }

        // we treat any dependencies with provided scope as library JARs
        for ( Artifact artifact : project.getArtifacts() )
        {
            if ( artifact.getScope().equals( JavaScopes.PROVIDED ) )
            {
                if ( artifact.getArtifactId().equals( "android" ) && parsedIncludeJdkLibs )
                {
                    addLibraryJar( artifact.getFile().getAbsolutePath(), ANDROID_LIBRARY_EXCLUDED_FILTER );
                }
                else
                {
                    addLibraryJar( artifact.getFile().getAbsolutePath() );
                }
            }
            else
            {
                if ( isShiftedArtifact( artifact ) )
                {
                    // this is a blacklisted artifact that should be processed as a library instead
                    addLibraryJar( artifact.getFile().getAbsolutePath() );
                }
            }
        }
    } 
                            #location 11 
                            #vulnerability type NULL_DEREFERENCE
#fixed code
                                private void collectLibraryInputFiles()
    {
        if ( parsedIncludeJdkLibs )
        {
            final String slash = File.separator;
            // we have to add the Java framework classes to the library JARs, since they are not
            // distributed with the JAR on Central, and since we'll strip them out of the android.jar
            // that is shipped with the SDK (since that is not a complete Java distribution)
            String javaHome = System.getProperty( "java.home" );
            String jdkLibsPath = null;
            if ( isMacOSXJDKbyApple( javaHome ) )
            {
                // MacOS X uses different naming conventions for JDK installations
                jdkLibsPath = appleJDKLibsPath( javaHome );
                addLibraryJar( jdkLibsPath + "/classes.jar" );
            }
            else
            {
                jdkLibsPath = javaHome + slash + "lib";
                addLibraryJar( jdkLibsPath + slash + "rt.jar" );
            }
            // we also need to add the JAR containing e.g. javax.servlet
            addLibraryJar( jdkLibsPath + slash + "jsse.jar" );
            // and the javax.crypto stuff
            addLibraryJar( jdkLibsPath + slash + "jce.jar" );
        }

        // we treat any dependencies with provided scope as library JARs
        for ( Artifact artifact : project.getArtifacts() )
        {
            if ( artifact.getScope().equals( JavaScopes.PROVIDED ) )
            {
                if ( artifact.getArtifactId().equals( "android" ) && parsedIncludeJdkLibs )
                {
                    addLibraryJar( artifact.getFile().getAbsolutePath(), ANDROID_LIBRARY_EXCLUDED_FILTER );
                }
                else
                {
                    addLibraryJar( artifact.getFile().getAbsolutePath() );
                }
            }
            else
            {
                if ( isShiftedArtifact( artifact ) )
                {
                    // this is a blacklisted artifact that should be processed as a library instead
                    addLibraryJar( artifact.getFile().getAbsolutePath() );
                }
            }
        }
    }