cordova-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dillon Lucente (JIRA)" <>
Subject [jira] [Commented] (CB-3761) XHR Crash using Cordova
Date Tue, 02 Jul 2013 17:01:23 GMT


Dillon Lucente commented on CB-3761:

I did receive success and error callbacks with the proposed change to cordova.js once I made
the request after the 'deviceready' event was triggered on the document instead of the jQuery
ready function. I just was doing a basic capabilities test, though, with a json file in the
root www folder.

It was also necessary to prefix the request with 'www/', like you mentioned, but was able
to just use a relative path, since the C# code was working at that point.

It'd be great if cordova.js could add this for us on the Windows platform so we didn't have
to add that in ourselves, but it's not that huge of a deal.
> XHR Crash using Cordova
> -----------------------
>                 Key: CB-3761
>                 URL:
>             Project: Apache Cordova
>          Issue Type: Bug
>          Components: WP8
>    Affects Versions: 2.8.0
>         Environment: Windows 8, Visual Studio 11, WP Simulator and Device
>            Reporter: Dillon Lucente
>            Assignee: Jesse MacFadyen
> 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.

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see:

View raw message