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

FileTransfer.download fails on Android 4.0

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 1.3.0
    • 1.4.0
    • cordova-android
    • None
    • This bug is only reproducible on Android 4.0. It works on earlier versions of Android.

    Description

      This bug was reported by Sumit Verma (sumit [dot] verma [at] ten24web [dot] com) and verified by me.

      Anyway, Ray was helping me with file download. Using his example ( http://www.raymondcamden.com/index.cfm/2012/1/19/Downloading-files-to-a-PhoneGap-application--Part-1 ) I got it to work in iOS and Android 2.3.3 but, I keep getting error in Android 4.0.3 AVD and in ASUS Prime. Here is the error:

      01-24 00:48:33.855: D/FileUploader(525): http://www.raymondcamden.com/demos/2012/jan/17/demotivational-posters-muppet-x-men.jpg
      01-24 00:48:33.855: D/FileUploader(525): java.io.FileNotFoundException: http://www.raymondcamden.com/demos/2012/jan/17/demotivational-posters-muppet-x-men.jpg
      01-24 00:48:33.855: D/FileUploader(525): at libcore.net.http.HttpURLConnectionImpl.getInputStream(HttpURLConnectionImpl.java:177)
      01-24 00:48:33.855: D/FileUploader(525): at com.phonegap.FileTransfer.download(FileTransfer.java:394)
      01-24 00:48:33.855: D/FileUploader(525): at com.phonegap.FileTransfer.execute(FileTransfer.java:102)
      01-24 00:48:33.855: D/FileUploader(525): at com.phonegap.api.PluginManager$1.run(PluginManager.java:150)
      01-24 00:48:33.855: D/FileUploader(525): at java.lang.Thread.run(Thread.java:856)
      01-24 00:48:33.865: E/FileUploader(525): Error while downloading
      01-24 00:48:33.865: E/FileUploader(525): java.io.IOException: Error while downloading
      01-24 00:48:33.865: E/FileUploader(525): at com.phonegap.FileTransfer.download(FileTransfer.java:415)
      01-24 00:48:33.865: E/FileUploader(525): at com.phonegap.FileTransfer.execute(FileTransfer.java:102)
      01-24 00:48:33.865: E/FileUploader(525): at com.phonegap.api.PluginManager$1.run(PluginManager.java:150)
      01-24 00:48:33.865: E/FileUploader(525): at java.lang.Thread.run(Thread.java:856)

      Attachments

        Activity

          People

            macdonst Simon MacDonald
            macdonst Simon MacDonald
            Votes:
            1 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: