{"action":"closed","issue":{"url":"https://api.github.com/repos/bkaradzic/bgfx/issues/985","repository_url":"https://api.github.com/repos/bkaradzic/bgfx","labels_url":"https://api.github.com/repos/bkaradzic/bgfx/issues/985/labels{/name}","comments_url":"https://api.github.com/repos/bkaradzic/bgfx/issues/985/comments","events_url":"https://api.github.com/repos/bkaradzic/bgfx/issues/985/events","html_url":"https://github.com/bkaradzic/bgfx/issues/985","id":190768659,"number":985,"title":"Sigsegv on Android","user":{"login":"wenq1","id":110781,"avatar_url":"https://avatars.githubusercontent.com/u/110781?v=3","gravatar_id":"","url":"https://api.github.com/users/wenq1","html_url":"https://github.com/wenq1","followers_url":"https://api.github.com/users/wenq1/followers","following_url":"https://api.github.com/users/wenq1/following{/other_user}","gists_url":"https://api.github.com/users/wenq1/gists{/gist_id}","starred_url":"https://api.github.com/users/wenq1/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wenq1/subscriptions","organizations_url":"https://api.github.com/users/wenq1/orgs","repos_url":"https://api.github.com/users/wenq1/repos","events_url":"https://api.github.com/users/wenq1/events{/privacy}","received_events_url":"https://api.github.com/users/wenq1/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2016-11-21T16:32:31Z","updated_at":"2016-11-21T17:52:07Z","closed_at":"2016-11-21T17:52:07Z","body":"Thanks for the great lib!\r\n\r\nCode below doesn't work as expected.\r\n```\r\n\t\t\tif (BX_ENABLED(BX_PLATFORM_EMSCRIPTEN)\r\n\t\t\t&&  BX_UNLIKELY(!isPtrAligned(_data, 4) ) )\r\n\t\t\t{\r\n\t\t\t\taddUnaligned(_data, _len);\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\r\n\t\t\taddAligned(_data, _len);\r\n```\r\n\r\nIt seems to me that the `UNLIKELY` is very likely on Android, so this so called MurmurHash will addAligned () and do this, hence a SIGBUS ...\r\n\r\n```\r\n\t\t\t\tuint32_t kk = *(uint32_t*)data;\r\n```\r\n\r\nLogcat below\r\n```\r\nE/BGFX: (10612): glstringhash: 0x7567357b, OpenGL ES 3.0 V@84.0 AU@04.04.04.157.009 (CL@)\r\nE/BGFX: (10612): addaligned: 0x7567357b, 46\r\n\r\n### 0x7567357b is surely not aligned!\r\n\r\n```\r\n"}}
{"actor":{"display_login":"bkaradzic"}}