{ "id": "64142", "key": "TIMOB-3510", "fields": { "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false }, "project": { "id": "10153", "key": "TIMOB", "name": "Titanium SDK/CLI", "projectCategory": { "id": "10100", "description": "Titanium and related SDKs used in application development", "name": "Client" } }, "fixVersions": [], "resolution": { "id": "3", "description": "The problem is a duplicate of an existing issue.", "name": "Duplicate" }, "resolutiondate": "2011-04-15T03:46:06.000+0000", "created": "2011-04-15T03:46:05.000+0000", "priority": { "name": "Trivial", "id": "5" }, "labels": [ "android", "defect" ], "versions": [], "issuelinks": [], "assignee": { "name": "dthorp", "key": "dthorp", "displayName": "Don Thorp", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2017-03-29T22:15:05.000+0000", "status": { "description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.", "name": "Closed", "id": "6", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "components": [ { "id": "10202", "name": "Android", "description": "Android Platform" } ], "description": "{html}

I've been going over this, and I'm fairly certain this is a\nbug.

\n

Here's the minimal test that will crash on Android with\nSIGSEGV:

\n

var win = Ti.UI.createWindow({

\n
\n// Android\nnavBarHidden: false,\nexitOnClose: true\n
\n

}); var view = Ti.UI.createWebView({

\n
\nscalesPageToFit: false,\nurl: 'something.html'\n
\n

}); view.addEventListener('load', function() {

\n
\nview.evalJS(\"test\");\n
\n

}); win.add(view);
\nwin.open();

\n

(Although I find it hard to believe people aren't somehow using\nevalJS() on Android. You'd think it would be a higher-profile\nissue.)

\n

Anyway, that code gives a crash dump similar to http://pastie.org/1754641.

{html}", "attachment": [], "flagged": false, "summary": "Android evalJS crashing with SIGSEGV", "creator": { "name": "kt", "key": "kt", "displayName": "KT", "active": true, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "kt", "key": "kt", "displayName": "KT", "active": true, "timeZone": "America/Los_Angeles" }, "environment": null, "comment": { "comments": [ { "id": "130729", "author": { "name": "kt", "key": "kt", "displayName": "KT", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

Sorry about that formatting. I just realized how it pasted.\nHopefully this is better.

\n

(Also, confirming that this crash also happens with 1.7\nbeta.)

\n
\nvar win = Ti.UI.createWindow({\n    // Android\n    navBarHidden: false,\n    exitOnClose: true\n});\nvar view = Ti.UI.createWebView({\n    scalesPageToFit: false,\n    url: 'something.html'\n});\nview.addEventListener('load', function() {\n    view.evalJS(\"test\");\n});\nwin.add(view);\nwin.open();\n
{html}", "updateAuthor": { "name": "kt", "key": "kt", "displayName": "KT", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T03:46:05.000+0000", "updated": "2011-04-15T03:46:05.000+0000" }, { "id": "130730", "author": { "name": "kt", "key": "kt", "displayName": "KT", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

Just as some further background and to help try to pinpoint it\nregression-wise, this issue seems to go back at least a year:

\n

http://developer.appcelerator.com/question/117750/android-evaljs

\n

\nhttp://developer.appcelerator.com/question/67431/js-to-webview-working-on-iphone-not-in-android

\n

\nhttp://developer.appcelerator.com/question/41671/problem-with-webviewevaljs---doesnt-seem-to-work-at-all-with-android-emulator

\n

\nhttp://developer.appcelerator.com/question/13431/evaljs-not-working-anymore-since-12x-upgrade-on-android-16

\n

This is, strangely, in direct contravention to your drillbit\ntest in:

\n

\nhttps://github.com/appcelerator/titanium_mobile/commit/597a4878af606e255811964cc5cbc9b93df5dfb2

\n

If that works, then what is drillbit doing differently so that\nit works whereas the app.js above crashes hard immediately?

{html}", "updateAuthor": { "name": "kt", "key": "kt", "displayName": "KT", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T03:46:05.000+0000", "updated": "2011-04-15T03:46:05.000+0000" }, { "id": "130731", "author": { "name": "kt", "key": "kt", "displayName": "KT", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

Further information: This crash doesn't seem to happen on 3.0.\nBut the necessary Ti Javascript seems to never get\ninjected, as is the case with 1.6 (i.e., no crash, but no Ti\ninjection).

{html}", "updateAuthor": { "name": "kt", "key": "kt", "displayName": "KT", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T03:46:05.000+0000", "updated": "2011-04-15T03:46:05.000+0000" }, { "id": "130732", "author": { "name": "hal", "key": "hal", "displayName": "hal", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

The information in this ticket has been moved to #3554

{html}", "updateAuthor": { "name": "dtoth", "key": "dtoth", "displayName": "Dawson Toth", "active": true, "timeZone": "America/New_York" }, "created": "2011-04-15T03:46:06.000+0000", "updated": "2011-04-26T07:23:48.000+0000" }, { "id": "416290", "author": { "name": "lmorris", "key": "lmorris", "displayName": "Lee Morris", "active": false, "timeZone": "America/Los_Angeles" }, "body": "Closing ticket as duplicate.", "updateAuthor": { "name": "lmorris", "key": "lmorris", "displayName": "Lee Morris", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2017-03-29T22:15:05.000+0000", "updated": "2017-03-29T22:15:05.000+0000" } ], "maxResults": 5, "total": 5, "startAt": 0 } } }