we have encountered a NullPointerException in the method "deleteEmptyParentFolders" of the class "BssIOUtils". It seems that the call "leafFolder.list()" returns null so that the call of the method "length" throws a NullPointerException.

We have fixed this by adding a new condition "leafFolder.list() != null" to the while head. Is this correct or has this side effects that we have missed?

Am 28.03.2011, 16:06 Uhr, schrieb SMILANewBee <nils.thieme@unister.de>:
> Hello,
>
> we have encountered a NullPointerException in the method
> "deleteEmptyParentFolders" of the class "BssIOUtils". It seems that the
> call "leafFolder.list()" returns null so that the call of the method
> "length" throws a NullPointerException.
>
> We have fixed this by adding a new condition "leafFolder.list() != null"
> to the while head. Is this correct or has this side effects that we have
> missed?

Thanks for the hint, the fix sounds OK to me. Probably a multi-threading
issue where
two threads try to delete the same folder at the same time? I will add the
fix to
our trunk.

Am 28.03.2011, 16:06 Uhr, schrieb SMILANewBee <nils.thieme@unister.de>:
> Hello,
>
> we have encountered a NullPointerException in the method
> "deleteEmptyParentFolders" of the class "BssIOUtils". It seems that the
> call "leafFolder.list()" returns null so that the call of the method
> "length" throws a NullPointerException.
>
> We have fixed this by adding a new condition "leafFolder.list() != null"
> to the while head. Is this correct or has this side effects that we have
> missed?

Thanks for the hint, the fix sounds OK to me. Probably a multi-threading
issue where
two threads try to delete the same folder at the same time? I will add the
fix to
our trunk.