Closed hohwille closed 8 years ago
Line 191 is:
for ( File file : sourceDir.listFiles() )
This would mean that sourceDir
is null.
How can this happen? It is the argument sourceFolder
from this code:
File sourceFolder = new File( sourceDir );
builder.addSourceFolder( sourceFolder );
if ( this.serviceClassName == null )
{
scanJavaFilesRecursive( sourceFolder, builder, serviceClasses );
}
Can File.listFiles()
return null or a File[]
with a null
entry?
OK. File.listFiles()
indeed returns null
if the path does not exist. Stupid one.
fixed with this commit (typo in issue number, sorry): https://github.com/mojohaus/servicedocgen-maven-plugin/commit/bfe86535eb5b02eab94f10fefca46fdffab435af