{ "id": "147575", "key": "AC-845", "fields": { "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false }, "project": { "id": "12217", "key": "AC", "name": "Appcelerator - INBOX", "projectCategory": { "id": "10000", "description": "", "name": "Customer Service" } }, "resolution": { "id": "5", "description": "All attempts at reproducing this issue failed, or not enough information was available to reproduce the issue. Reading the code produces no clues as to why this behavior would occur. If more information appears later, please reopen the issue.", "name": "Cannot Reproduce" }, "resolutiondate": "2015-09-30T02:50:39.000+0000", "created": "2015-05-06T08:11:23.000+0000", "labels": [ "ios" ], "versions": [], "issuelinks": [], "assignee": { "name": "shossain", "key": "shossain", "displayName": "Shak Hossain", "active": false, "timeZone": "America/Los_Angeles" }, "updated": "2016-03-08T07:37:08.000+0000", "status": { "description": "A resolution has been taken, and it is awaiting verification by reporter. From here issues are either reopened, or are closed.", "name": "Resolved", "id": "5", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "components": [ { "id": "14548", "name": "Titanium SDK & CLI", "description": "Please enter tickets related to the MobileSDK here." } ], "description": "The following statement crashes on iPhone:\r\n{{String.format(\" & %1$s more...\", \"a, b, c\", 5);}}\r\n*Notes*\r\n# I'm passing an integer as a string argument (%s)\r\n# This doesn't raise a runtime error, it crashes out of the app straight to the launcher\r\n# This may be a *security problem*. I don't have time to attempt an exploit, but I have a feeling that there is one...\r\n# This works perfectly on Android\r\n# C-style printf is not appropriate for Javascript. You should replace this with some sort of typeless template replacement.\r\n\r\nReplacing 5 with \"\"+5 results in \"more...\" being dropped:\r\n{{String.format(\" & %1$s more...\", \"a, b, c\", \"\"+5);}}\r\nresults with\r\n{{a, b, c & 5}}", "attachment": [ { "id": "55283", "filename": "iOS Simulator Screen Shot May 7, 2015, 6.47.01 PM.png", "author": { "name": "hmrida", "key": "hmrida", "displayName": "Harish Mridha", "active": true, "timeZone": "Asia/Dhaka" }, "created": "2015-05-07T12:52:44.000+0000", "size": 26668, "mimeType": "image/png" }, { "id": "55282", "filename": "iOS Simulator Screen Shot May 7, 2015, 6.48.26 PM.png", "author": { "name": "hmrida", "key": "hmrida", "displayName": "Harish Mridha", "active": true, "timeZone": "Asia/Dhaka" }, "created": "2015-05-07T12:52:44.000+0000", "size": 26685, "mimeType": "image/png" } ], "flagged": false, "summary": "Strings.format crashes on iOS", "creator": { "name": "buddyguards", "key": "buddyguards", "displayName": "grebulon", "active": true, "timeZone": "Asia/Jerusalem" }, "subtasks": [], "reporter": { "name": "buddyguards", "key": "buddyguards", "displayName": "grebulon", "active": true, "timeZone": "Asia/Jerusalem" }, "environment": "Titanium 3.5.0 on iOS", "comment": { "comments": [ { "id": "351919", "author": { "name": "hmrida", "key": "hmrida", "displayName": "Harish Mridha", "active": true, "timeZone": "Asia/Dhaka" }, "body": "Hi ,\r\n\r\nWe have tested this issue and unable to reproduce it. We used the following test case. If you can provide us a test sample that reproduces the issue, we will investigate it further.\r\n\r\nPlease find the screen sort.\r\n{code}\r\nvar w = Ti.UI.createWindow({\r\n backgroundColor: 'white'\r\n});\r\n \r\nw.add(Ti.UI.createLabel({\r\n //text: String.format(\" & %1$s more...\", \"a, b, c\", 5),\r\n text:String.format(\" & %1$s more...\", \"a, b, c\", \"\"+5),\r\n \r\n}));\r\n \r\nw.open();\r\n{code}\r\n\r\nThanks", "updateAuthor": { "name": "shossain", "key": "shossain", "displayName": "Shak Hossain", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2015-05-07T12:52:24.000+0000", "updated": "2015-09-30T02:50:32.000+0000" } ], "maxResults": 2, "total": 2, "startAt": 0 } } }