[AC-1628] Simple WebView crashes 3.2.2 -> 3.3.0 in HTC Evo V
| GitHub Issue | n/a |
|---|---|
| Type | Bug |
| Priority | n/a |
| Status | Resolved |
| Resolution | Duplicate |
| Resolution Date | 2014-05-13T17:19:08.000+0000 |
| Affected Version/s | n/a |
| Fix Version/s | n/a |
| Components | n/a |
| Labels | n/a |
| Reporter | Andrew Greenstreet |
| Assignee | Ritu Agrawal |
| Created | 2014-05-12T21:50:28.000+0000 |
| Updated | 2016-03-08T07:38:06.000+0000 |
Description
The following Code (this is the complete project)
var win = Titanium.UI.createWindow();
win.add(Ti.UI.createWebView({url:"http://google.com"}));
win.open();
Crashes on an HTC EVO V (Android 4.0.3)
The same code works fine on 3.2.1 and 3.1.4.
I have confirmed this in
3.2.2.GA
3.2.3.GA
3.2.4 (latest build)
3.3.0 (latest build)
[ERROR] : TiApplication: (main) [6910,6910] Sending event: exception on thread: main msg:java.lang.NullPointerException; Titanium 3.2.4,2014/05/08 11:33,f6bc2e4
[ERROR] : TiApplication: java.lang.NullPointerException
[ERROR] : TiApplication: at android.webkit.WebView$PrivateHandler.handleMessage(WebView.java:9710)
[ERROR] : TiApplication: at android.os.Handler.dispatchMessage(Handler.java:99)
[ERROR] : TiApplication: at android.os.Looper.loop(Looper.java:154)
[ERROR] : TiApplication: at android.app.ActivityThread.main(ActivityThread.java:4945)
[ERROR] : TiApplication: at java.lang.reflect.Method.invokeNative(Native Method)
[ERROR] : TiApplication: at java.lang.reflect.Method.invoke(Method.java:511)
[ERROR] : TiApplication: at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:784)
[ERROR] : TiApplication: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:551)
[ERROR] : TiApplication: at dalvik.system.NativeStart.main(Native Method)
[ERROR] : chromium: external/chromium/net/disk_cache/stat_hub.cc:190: [0512/144618:ERROR:stat_hub.cc(190)] StatHub::Init - App com.gsm.testWebView isn't supported.
[ERROR] : chromium: external/chromium/net/disk_cache/stat_hub.cc:190: [0512/144618:ERROR:stat_hub.cc(190)] StatHub::Init - App com.gsm.testWebView isn't supported.
[INFO] : qtaguid: Failed write_ctrl(t 108 43550968381440 26113048) res=-1 errno=1
I'd also note that the crash doesn't happen until the Webview is added to another View. E.g.
Will crash as soon as the webview is addedvar win = Ti.UI.createWindow(); var webview = Ti.UI.createWebView({url:"http://google.com"}); win.open(); setTimeout(function(){ win.add(webview)}, 2000);Thank you for bringing this to our attention. TIMOB-16952 has created for this issue. Please watch TIMOB-16952 for latest updates.