{"action":"created","issue":{"url":"https://api.github.com/repos/unicorn-engine/unicorn/issues/248","labels_url":"https://api.github.com/repos/unicorn-engine/unicorn/issues/248/labels{/name}","comments_url":"https://api.github.com/repos/unicorn-engine/unicorn/issues/248/comments","events_url":"https://api.github.com/repos/unicorn-engine/unicorn/issues/248/events","html_url":"https://github.com/unicorn-engine/unicorn/pull/248","id":115275637,"number":248,"title":"X86 zero-byte opcode causes Unicorn to crash.","user":{"login":"farmdve","id":7746376,"avatar_url":"https://avatars.githubusercontent.com/u/7746376?v=3","gravatar_id":"","url":"https://api.github.com/users/farmdve","html_url":"https://github.com/farmdve","followers_url":"https://api.github.com/users/farmdve/followers","following_url":"https://api.github.com/users/farmdve/following{/other_user}","gists_url":"https://api.github.com/users/farmdve/gists{/gist_id}","starred_url":"https://api.github.com/users/farmdve/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/farmdve/subscriptions","organizations_url":"https://api.github.com/users/farmdve/orgs","repos_url":"https://api.github.com/users/farmdve/repos","events_url":"https://api.github.com/users/farmdve/events{/privacy}","received_events_url":"https://api.github.com/users/farmdve/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-11-05T12:41:28Z","updated_at":"2015-11-05T12:51:52Z","closed_at":"2015-11-05T12:49:04Z","pull_request":{"url":"https://api.github.com/repos/unicorn-engine/unicorn/pulls/248","html_url":"https://github.com/unicorn-engine/unicorn/pull/248","diff_url":"https://github.com/unicorn-engine/unicorn/pull/248.diff","patch_url":"https://github.com/unicorn-engine/unicorn/pull/248.patch"},"body":"The opcode 0x00 translates as `add byte ptr ds:[eax],al`, which leads to\r\na segfault in Unicorn.\r\n\r\nUsing a debugger, I believe the crash is located in\r\n`qemu/translate-all.c` in function `page_flush_tb_1`, more specifically\r\nthis code `pd[i].first_tb = NULL;`"},"comment":{"url":"https://api.github.com/repos/unicorn-engine/unicorn/issues/comments/154050331","html_url":"https://github.com/unicorn-engine/unicorn/pull/248#issuecomment-154050331","issue_url":"https://api.github.com/repos/unicorn-engine/unicorn/issues/248","id":154050331,"user":{"login":"farmdve","id":7746376,"avatar_url":"https://avatars.githubusercontent.com/u/7746376?v=3","gravatar_id":"","url":"https://api.github.com/users/farmdve","html_url":"https://github.com/farmdve","followers_url":"https://api.github.com/users/farmdve/followers","following_url":"https://api.github.com/users/farmdve/following{/other_user}","gists_url":"https://api.github.com/users/farmdve/gists{/gist_id}","starred_url":"https://api.github.com/users/farmdve/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/farmdve/subscriptions","organizations_url":"https://api.github.com/users/farmdve/orgs","repos_url":"https://api.github.com/users/farmdve/repos","events_url":"https://api.github.com/users/farmdve/events{/privacy}","received_events_url":"https://api.github.com/users/farmdve/received_events","type":"User","site_admin":false},"created_at":"2015-11-05T12:51:52Z","updated_at":"2015-11-05T12:51:52Z","body":"Wow, sorry for that. I make sure to double-check everything before I submit, but I guess I didn't. With \\x00\\x00 there is no crash, however with just the one byte there is."}}