Sahoo wrote:
Fiona,
I think I have a solution for the URISyntaxError. Can you please file
a bug and I shall upload a patch for the same?
Thanks,
Sahoo
Fiona Mahon wrote:
[...]
When I define felix.fileinstall.dir="watchedDir" (i.e. with quotes
around the directory) I get the endless loop, when I start up the
container. here's a bit of the output:
ERROR 20090612 10:08:33 bid#11 - In main loop, we have
serious trouble
(java.lang.NullPointerException)
java.lang.NullPointerException
at
org.apache.felix.fileinstall.DirectoryWatcher.traverse(DirectoryWatch
er.java:439)
at
org.apache.felix.fileinstall.DirectoryWatcher.run(DirectoryWatcher.ja
va:120)
ERROR 20090612 10:08:33 bid#11 - In main loop, we have
serious trouble
(java.lang.NullPointerException)
java.lang.NullPointerException
at
org.apache.felix.fileinstall.DirectoryWatcher.traverse(DirectoryWatch
er.java:439)
at
org.apache.felix.fileinstall.DirectoryWatcher.run(DirectoryWatcher.ja
va:120)
(this is an endless loop of output)
Hi Sahoo, I was able to reproduce the "looping NullPointerException"
scenario above.
I've taken a look at the code and I think that this is due to these
lines in DirectoryWatcher:
void traverse(Map/* <String, Jar> */ jars, Set configs, File jardir)
{
String list[] = jardir.list();
for (int i = 0; i < list.length; i++)
which, IMHO, should become:
void traverse(Map/* <String, Jar> */ jars, Set configs, File jardir)
{
String list[] = jardir.list();
for (int i = 0; (list!=null) && (i < list.length); i++)
jardir.list() will return null if the jardir File object is not
associated to a Directory (see [1]).
[1]: http://java.sun.com/j2se/1.4.2/docs/api/java/io/File.html#list()
--
Guido
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]