{ "id": "113130", "key": "TIMOB-13730", "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": null, "resolutiondate": null, "created": "2013-04-19T15:15:20.000+0000", "priority": { "name": "Low", "id": "4" }, "labels": [], "versions": [ { "id": "14162", "description": "Release 3.1.0", "name": "Release 3.1.0", "archived": true, "released": true, "releaseDate": "2013-04-16" } ], "issuelinks": [], "assignee": null, "updated": "2018-02-28T20:04:12.000+0000", "status": { "description": "This issue was once resolved, but the resolution was deemed incorrect. From here issues are either marked assigned or resolved.", "name": "Reopened", "id": "4", "statusCategory": { "id": 2, "key": "new", "colorName": "blue-gray", "name": "To Do" } }, "components": [], "description": "*Problem description*\r\nThe following test case causes Java process to crash on Android with local ref table overflow error as shown in the log below.\r\n\r\n*Test case*\r\n{code:javascript}\r\nvar getdcaps = function() {\r\n\tvar a = [];\r\n\tfor (i = 0; i < 1000; i++) {\r\n\t\ta.push(Ti.Platform.displayCaps);\r\n\t}\r\n\treturn a;\r\n}\r\nTi.API.info(\"getdcaps length: \" + getdcaps().length);\r\n{code}\r\n\r\n*Log*\r\n{code}\r\n04-19 15:11:21.583: E/dalvikvm(2243): JNI ERROR (app bug): local reference table overflow (max=512)\r\n04-19 15:11:21.583: W/dalvikvm(2243): JNI local reference table (0xb9f763b0) dump:\r\n04-19 15:11:21.593: W/dalvikvm(2243): Last 10 entries (of 512):\r\n04-19 15:11:21.593: W/dalvikvm(2243): 511: 0xb4447688 ti.modules.titanium.platform.DisplayCapsProxy\r\n04-19 15:11:21.593: W/dalvikvm(2243): 510: 0xb4447688 ti.modules.titanium.platform.DisplayCapsProxy\r\n04-19 15:11:21.593: W/dalvikvm(2243): 509: 0xb4447688 ti.modules.titanium.platform.DisplayCapsProxy\r\n04-19 15:11:21.593: W/dalvikvm(2243): 508: 0xb4447688 ti.modules.titanium.platform.DisplayCapsProxy\r\n04-19 15:11:21.593: W/dalvikvm(2243): 507: 0xb4447688 ti.modules.titanium.platform.DisplayCapsProxy\r\n04-19 15:11:21.593: W/dalvikvm(2243): 506: 0xb4447688 ti.modules.titanium.platform.DisplayCapsProxy\r\n04-19 15:11:21.593: W/dalvikvm(2243): 505: 0xb4447688 ti.modules.titanium.platform.DisplayCapsProxy\r\n04-19 15:11:21.593: W/dalvikvm(2243): 504: 0xb4447688 ti.modules.titanium.platform.DisplayCapsProxy\r\n04-19 15:11:21.593: W/dalvikvm(2243): 503: 0xb4447688 ti.modules.titanium.platform.DisplayCapsProxy\r\n04-19 15:11:21.593: W/dalvikvm(2243): 502: 0xb4447688 ti.modules.titanium.platform.DisplayCapsProxy\r\n04-19 15:11:21.593: W/dalvikvm(2243): Summary:\r\n04-19 15:11:21.593: W/dalvikvm(2243): 2 of java.lang.String (2 unique instances)\r\n04-19 15:11:21.593: W/dalvikvm(2243): 1 of org.appcelerator.kroll.runtime.v8.V8Runtime\r\n04-19 15:11:21.593: W/dalvikvm(2243): 2 of org.appcelerator.titanium.proxy.ActivityProxy (1 unique instances)\r\n04-19 15:11:21.593: W/dalvikvm(2243): 1 of ti.modules.titanium.platform.PlatformModule\r\n04-19 15:11:21.593: W/dalvikvm(2243): 506 of ti.modules.titanium.platform.DisplayCapsProxy (1 unique instances)\r\n04-19 15:11:21.593: E/dalvikvm(2243): Failed adding to JNI local ref table (has 512 entries)\r\n04-19 15:11:21.593: I/dalvikvm(2243): \"KrollRuntimeThread\" prio=5 tid=11 RUNNABLE\r\n04-19 15:11:21.593: I/dalvikvm(2243): | group=\"main\" sCount=0 dsCount=0 obj=0xb44128c8 self=0xb9f97070\r\n04-19 15:11:21.593: I/dalvikvm(2243): | sysTid=2258 nice=0 sched=0/0 cgrp=[fopen-error:2] handle=-1174825904\r\n04-19 15:11:21.593: I/dalvikvm(2243): | state=R schedstat=( 0 0 0 ) utm=5 stm=2 core=0\r\n04-19 15:11:21.603: I/dalvikvm(2243): at org.appcelerator.kroll.runtime.v8.V8Runtime.nativeRunModule(Native Method)\r\n04-19 15:11:21.603: I/dalvikvm(2243): at org.appcelerator.kroll.runtime.v8.V8Runtime.doRunModule(V8Runtime.java:159)\r\n04-19 15:11:21.603: I/dalvikvm(2243): at org.appcelerator.kroll.KrollRuntime.handleMessage(KrollRuntime.java:289)\r\n04-19 15:11:21.603: I/dalvikvm(2243): at org.appcelerator.kroll.runtime.v8.V8Runtime.handleMessage(V8Runtime.java:185)\r\n04-19 15:11:21.603: I/dalvikvm(2243): at android.os.Handler.dispatchMessage(Handler.java:95)\r\n04-19 15:11:21.603: I/dalvikvm(2243): at android.os.Looper.loop(Looper.java:137)\r\n04-19 15:11:21.603: I/dalvikvm(2243): at org.appcelerator.kroll.KrollRuntime$KrollRuntimeThread.run(KrollRuntime.java:112)\r\n04-19 15:11:21.603: E/dalvikvm(2243): VM aborting\r\n04-19 15:11:21.603: A/libc(2243): Fatal signal 11 (SIGSEGV) at 0xdeadd00d (code=1), thread 2258 (KrollRuntimeThr)\r\n04-19 15:11:21.725: I/DEBUG(792): *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***\r\n04-19 15:11:21.725: I/DEBUG(792): Build fingerprint: 'generic_x86/sdk_x86/generic_x86:4.2/JOP40C/eng.android-build.20121231.103448:eng/test-keys'\r\n04-19 15:11:21.725: I/DEBUG(792): Revision: '0'\r\n04-19 15:11:21.725: I/DEBUG(792): pid: 2243, tid: 2258, name: UNKNOWN >>> ru.mobileorders.gemm.pf <<<\r\n04-19 15:11:21.725: I/DEBUG(792): signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr deadd00d\r\n04-19 15:11:21.803: I/DEBUG(792): eax 0000020c ebx b733eff4 ecx 00000001 edx 00000000\r\n04-19 15:11:21.803: I/DEBUG(792): esi ab91423c edi 0000020c\r\n04-19 15:11:21.813: I/DEBUG(792): xcs 00000073 xds 0000007b xes 0000007b xfs 00000000 xss 0000007b\r\n04-19 15:11:21.813: I/DEBUG(792): eip b72800f2 ebp b733fc80 esp ab914220 flags 00010246\r\n04-19 15:11:21.813: I/DEBUG(792): backtrace:\r\n04-19 15:11:21.813: I/DEBUG(792): #00 pc 0005e0f2 /system/lib/libdvm.so (dvmAbort+178)\r\n04-19 15:11:21.813: I/DEBUG(792): stack:\r\n04-19 15:11:21.813: I/DEBUG(792): ab9141e0 00000000 \r\n04-19 15:11:21.813: I/DEBUG(792): ab9141e4 00000000 \r\n04-19 15:11:21.813: I/DEBUG(792): ab9141e8 00000000 \r\n04-19 15:11:21.813: I/DEBUG(792): ab9141ec 00000000 \r\n04-19 15:11:21.813: I/DEBUG(792): ab9141f0 00000000 \r\n04-19 15:11:21.813: I/DEBUG(792): ab9141f4 00000000 \r\n04-19 15:11:21.813: I/DEBUG(792): ab9141f8 00000000 \r\n04-19 15:11:21.813: I/DEBUG(792): ab9141fc 00000000 \r\n04-19 15:11:21.813: I/DEBUG(792): ab914200 00000000 \r\n04-19 15:11:21.813: I/DEBUG(792): ab914204 00000000 \r\n04-19 15:11:21.813: I/DEBUG(792): ab914208 00000000 \r\n04-19 15:11:21.813: I/DEBUG(792): ab91420c 00000000 \r\n04-19 15:11:21.823: I/DEBUG(792): ab914210 00000000 \r\n04-19 15:11:21.823: I/DEBUG(792): ab914214 00000000 \r\n04-19 15:11:21.823: I/DEBUG(792): ab914218 00000000 \r\n04-19 15:11:21.823: I/DEBUG(792): ab91421c 00000000 \r\n04-19 15:11:21.823: I/DEBUG(792): #00 ab914220 00000000 \r\n04-19 15:11:21.823: I/DEBUG(792): ab914224 b7305a9d /system/lib/libdvm.so\r\n04-19 15:11:21.823: I/DEBUG(792): ab914228 b7306c9b /system/lib/libdvm.so\r\n04-19 15:11:21.823: I/DEBUG(792): ab91422c 00000000 \r\n04-19 15:11:21.823: I/DEBUG(792): ab914230 ba002a30 [heap]\r\n04-19 15:11:21.823: I/DEBUG(792): ab914234 b7305a9d /system/lib/libdvm.so\r\n04-19 15:11:21.823: I/DEBUG(792): ab914238 b7305f0b /system/lib/libdvm.so\r\n04-19 15:11:21.823: I/DEBUG(792): ab91423c 6c756e28 \r\n04-19 15:11:21.823: I/DEBUG(792): ab914240 0000296c \r\n04-19 15:11:21.823: I/DEBUG(792): ab914244 00000000 \r\n04-19 15:11:21.823: I/DEBUG(792): ab914248 00000000 \r\n04-19 15:11:21.823: I/DEBUG(792): ab91424c 00000000 \r\n04-19 15:11:21.823: I/DEBUG(792): ab914250 00000000 \r\n04-19 15:11:21.823: I/DEBUG(792): ab914254 00000000 \r\n04-19 15:11:21.823: I/DEBUG(792): ab914258 00000000 \r\n04-19 15:11:21.823: I/DEBUG(792): ab91425c 00000000 \r\n04-19 15:11:21.823: I/DEBUG(792): ........ ........\r\n04-19 15:11:21.823: I/DEBUG(792): memory map around fault addr deadd00d:\r\n04-19 15:11:21.833: I/DEBUG(792): bf95d000-bf972000 [stack]\r\n04-19 15:11:21.833: I/DEBUG(792): (no map for address)\r\n04-19 15:11:21.833: I/DEBUG(792): (no map above)\r\n04-19 15:11:21.853: I/BootReceiver(1189): Copying /data/tombstones/tombstone_08 to DropBox (SYSTEM_TOMBSTONE)\r\n04-19 15:11:21.863: D/Zygote(795): Process 2243 terminated by signal (11)\r\n04-19 15:11:21.863: I/ActivityManager(1189): Process ru.mobileorders.gemm.pf (pid 2243) has died.\r\n04-19 15:11:21.873: I/dalvikvm(2262): Turning on JNI app bug workarounds for target SDK version 7...\r\n04-19 15:11:21.873: I/ActivityManager(1189): Start proc ru.mobileorders.gemm.pf for activity ru.mobileorders.gemm.pf/.PeoplesfoodActivity: pid=2262 uid=10046 gids={50046, 1015, 3003, 1028}\r\n04-19 15:11:21.873: W/Trace(1189): Unexpected value from nativeGetEnabledTags: 0\r\n04-19 15:11:21.873: W/Trace(1189): Unexpected value from nativeGetEnabledTags: 0\r\n04-19 15:11:21.873: W/Trace(1189): Unexpected value from nativeGetEnabledTags: 0\r\n04-19 15:11:21.883: W/Trace(1189): Unexpected value from nativeGetEnabledTags: 0\r\n04-19 15:11:21.883: E/Trace(2262): error opening trace file: No such file or directory (2)\r\n{code}", "attachment": [ { "id": "37680", "filename": "emulator-output.log", "author": { "name": "yurys", "key": "yurys", "displayName": "Yury Skaletskiy", "active": true, "timeZone": "Europe/Moscow" }, "created": "2013-04-19T18:33:18.000+0000", "size": 8774, "mimeType": "text/plain" }, { "id": "37681", "filename": "emulator-output.log", "author": { "name": "yurys", "key": "yurys", "displayName": "Yury Skaletskiy", "active": true, "timeZone": "Europe/Moscow" }, "created": "2013-04-19T18:33:18.000+0000", "size": 8774, "mimeType": "text/plain" }, { "id": "37682", "filename": "hardware-qemu.ini", "author": { "name": "yurys", "key": "yurys", "displayName": "Yury Skaletskiy", "active": true, "timeZone": "Europe/Moscow" }, "created": "2013-04-19T18:33:18.000+0000", "size": 1439, "mimeType": "application/octet-stream" }, { "id": "37679", "filename": "testcase.zip", "author": { "name": "yurys", "key": "yurys", "displayName": "Yury Skaletskiy", "active": true, "timeZone": "Europe/Moscow" }, "created": "2013-04-19T18:33:18.000+0000", "size": 752972, "mimeType": "application/zip" } ], "flagged": false, "summary": "Android: Ti.Platform.displayCaps crashes taking whole JNI local reference table", "creator": { "name": "yurys", "key": "yurys", "displayName": "Yury Skaletskiy", "active": true, "timeZone": "Europe/Moscow" }, "subtasks": [], "reporter": { "name": "yurys", "key": "yurys", "displayName": "Yury Skaletskiy", "active": true, "timeZone": "Europe/Moscow" }, "environment": "Android >= 4.2, 4.2.2 (atom x86 and ARM)\r\nTitanium Mobile SDK 3.1.0 GA, Alloy 1.0.0\r\nTitanium Studio 3.1", "comment": { "comments": [ { "id": "248390", "author": { "name": "dsefton", "key": "dsefton", "displayName": "Daniel Sefton", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Please ensure that the test case you provided runs. I'm getting a \"length is undefined\" error, and understandably so.", "updateAuthor": { "name": "dsefton", "key": "dsefton", "displayName": "Daniel Sefton", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2013-04-19T17:44:41.000+0000", "updated": "2013-04-19T17:44:41.000+0000" }, { "id": "248406", "author": { "name": "yurys", "key": "yurys", "displayName": "Yury Skaletskiy", "active": true, "timeZone": "Europe/Moscow" }, "body": "Please find attached the solution archive as well as full emulator log and its config files ", "updateAuthor": { "name": "yurys", "key": "yurys", "displayName": "Yury Skaletskiy", "active": true, "timeZone": "Europe/Moscow" }, "created": "2013-04-19T18:33:18.000+0000", "updated": "2013-04-19T18:33:18.000+0000" }, { "id": "249614", "author": { "name": "dsefton", "key": "dsefton", "displayName": "Daniel Sefton", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Tested and confirmed on Google APIs Android 4.2 Emulator [armeabi-v7a] with Ti SDK 3.1 GA, Alloy 1.1.1, Ti Studio 3.1.0.201304151600.\n\nIt does not crash on Android 4.1.2 and below however, on Android 4.1.2 x86 emulator, or Samsung Galaxy S2 Android 2.3.6. Test case runs without crash, printing the log as expected:\n\n{code}04-30 14:57:56.599: I/TiAPI(3963): getdcaps length: 1000{code}\n\nSo it's an Android OS version parity issue.", "updateAuthor": { "name": "dsefton", "key": "dsefton", "displayName": "Daniel Sefton", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2013-04-30T22:08:30.000+0000", "updated": "2013-04-30T22:08:30.000+0000" } ], "maxResults": 3, "total": 3, "startAt": 0 } } }