Uploaded image for project: 'Apache Cordova'
  1. Apache Cordova
  2. CB-6940

File plugin on Android causes app to fail to start if USB Mass Storage mode enabled and USB plugged in

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 3.5.0
    • None
    • cordova-plugin-file
    • None
    • Android 2.3.x-4.4.x
      Cordova 3.5.0-0.2.4
      File plugin 1.2.0

    Description

      When attempting to launch a Cordova application on Android that includes the File plugin, if the USB Mass Storage option is enabled and the USB cable is plugged in, the application stalls. In the system log, the following appears:

      ApplicationContext: Unable to create external files directory
      PluginManager: Uncaught exception from plugin
      PluginManager: java.lang.NullPointerException
      PluginManager: at org.apache.cordova.file.FileUtils.requestAllPaths(FileUtils.java:866)
      PluginManager: at org.apache.cordova.file.FileUtils.execute(FileUtils.java:348)
      PluginManager: at org.apache.cordova.CordovaPlugin.execute(CordovaPlugin.java:65)
      PluginManager: at org.apache.cordova.PluginManager.execHelper(PluginManager.java:242)
      PluginManager: at org.apache.cordova.PluginManager.exec(PluginManager.java:227)
      PluginManager: at org.apache.cordova.ExposedJsApi.exec(ExposedJsApi.java:53)
      PluginManager: at org.apache.cordova.CordovaChromeClient.onJsPrompt(CordovaChromeClient.java:227)
      PluginManager: at android.webkit.CallbackProxy.handleMessage(CallbackProxy.java:607)
      PluginManager: at android.os.Handler.dispatchMessage(Handler.java:99)
      PluginManager: at android.os.Looper.loop(Looper.java:137)
      PluginManager: at android.app.ActivityThread.main(ActivityThread.java:4722)
      PluginManager: at java.lang.reflect.Method.invokeNative(Native Method)
      PluginManager: at java.lang.reflect.Method.invoke(Method.java:511)
      PluginManager: at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:787)
      PluginManager: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:554)
      PluginManager: at dalvik.system.NativeStart.main(Native Method)

      Attachments

        Activity

          People

            Unassigned Unassigned
            jamespwhite James White
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: