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

XHR Crash using Cordova

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 2.8.0
    • 3.1.0
    • None
    • Windows 8, Visual Studio 11, WP Simulator and Device

    Description

      Out of bounds crash when trying to use Cordova.js overridden XHR.

      Affected files: FileUtil.cs (readResourceAsText() line 707) and Cordova.js (line 6258)

      Changes in the C# implementation haven't made their way back to the js implementation. readResourceAsText() expects an array of 5 elements, but the js is only supplying two arguments.

      Possible fixes:

      Change line 6258 of Cordova.js from:

      "File", "readResourceAsText", [alias._url]

      to:

      "File", "readResourceAsText", [alias._url, "", 0, 0]

      Or change readResourceAsText() to not try to assign variables it doesn't use.

      Attachments

        Issue Links

          Activity

            People

              purplecabbage Jesse MacFadyen
              dillonlucente Dillon Lucente
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: