Uploaded image for project: 'Felix'
  1. Felix
  2. FELIX-3211

org.apache.felix.framework.cache.BundleCache.deleteDirectoryTreeRecursive throws NPE

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • framework-4.0.0
    • framework-4.0.2
    • Framework
    • None
    • Windows 7 (32), Java 7

    Description

      The following exception was found in logs:
      org.osgi.framework.BundleException: Unable to flush bundle cache.
      at org.apache.felix.framework.Felix.init(Felix.java:652)
      at icom.AppMain.initApplicationOsgi(AppMain.java:257)
      at icom.AppMain.main(AppMain.java:145)
      Caused by: java.lang.NullPointerException
      at org.apache.felix.framework.cache.BundleCache.deleteDirectoryTreeRecursive(BundleCache.java:429)
      at org.apache.felix.framework.cache.BundleCache.deleteDirectoryTreeRecursive(BundleCache.java:431)
      at org.apache.felix.framework.cache.BundleCache.deleteDirectoryTree(BundleCache.java:371)
      at org.apache.felix.framework.cache.BundleCache.delete(BundleCache.java:213)
      at org.apache.felix.framework.Felix.init(Felix.java:648)
      ... 2 more
      The famework is started with the clear cache property.

      Looking at BundleCache code, it doesn't check for null on the return of getSecureAction().listDirectory(target) (which eventually calls Files.list() which can return null from the native call

      Attachments

        Activity

          People

            rickhall Richard S. Hall
            lhochet Ludovic HOCHET
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: