{"action":"created","issue":{"url":"https://api.github.com/repos/xbmc/xbmc/issues/9225","repository_url":"https://api.github.com/repos/xbmc/xbmc","labels_url":"https://api.github.com/repos/xbmc/xbmc/issues/9225/labels{/name}","comments_url":"https://api.github.com/repos/xbmc/xbmc/issues/9225/comments","events_url":"https://api.github.com/repos/xbmc/xbmc/issues/9225/events","html_url":"https://github.com/xbmc/xbmc/pull/9225","id":136942942,"number":9225,"title":"Fix out of memory crash in CArchive","user":{"login":"Paxxi","id":874927,"avatar_url":"https://avatars.githubusercontent.com/u/874927?v=3","gravatar_id":"","url":"https://api.github.com/users/Paxxi","html_url":"https://github.com/Paxxi","followers_url":"https://api.github.com/users/Paxxi/followers","following_url":"https://api.github.com/users/Paxxi/following{/other_user}","gists_url":"https://api.github.com/users/Paxxi/gists{/gist_id}","starred_url":"https://api.github.com/users/Paxxi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Paxxi/subscriptions","organizations_url":"https://api.github.com/users/Paxxi/orgs","repos_url":"https://api.github.com/users/Paxxi/repos","events_url":"https://api.github.com/users/Paxxi/events{/privacy}","received_events_url":"https://api.github.com/users/Paxxi/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/xbmc/xbmc/labels/Fix","name":"Fix","color":"0b02e1"},{"url":"https://api.github.com/repos/xbmc/xbmc/labels/Improvement","name":"Improvement","color":"0b02e1"}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":28,"created_at":"2016-02-27T17:15:45Z","updated_at":"2016-07-11T18:16:35Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/xbmc/xbmc/pulls/9225","html_url":"https://github.com/xbmc/xbmc/pull/9225","diff_url":"https://github.com/xbmc/xbmc/pull/9225.diff","patch_url":"https://github.com/xbmc/xbmc/pull/9225.patch"},"body":"This should fix this issue\r\n```\r\nThread 1 (Thread 0x7f6369ff3700 (LWP 13304)):\r\n#0  0x00007f63da306cc9 in __GI_raise (sig=sig@entry=6) at ../nptl/sysdeps/unix/sysv/linux/raise.c:56\r\n#1  0x00007f63da30a0d8 in __GI_abort () at abort.c:89\r\n#2  0x00007f63da90b535 in __gnu_cxx::__verbose_terminate_handler() () from /usr/lib/x86_64-linux-gnu/libstdc++.so.6\r\n#3  0x00007f63da9096d6 in ?? () from /usr/lib/x86_64-linux-gnu/libstdc++.so.6\r\n#4  0x00007f63da909703 in std::terminate() () from /usr/lib/x86_64-linux-gnu/libstdc++.so.6\r\n#5  0x00007f63da909922 in __cxa_throw () from /usr/lib/x86_64-linux-gnu/libstdc++.so.6\r\n#6  0x00007f63da909e0d in operator new(unsigned long) () from /usr/lib/x86_64-linux-gnu/libstdc++.so.6\r\n#7  0x00007f63da909ea9 in operator new[](unsigned long) () from /usr/lib/x86_64-linux-gnu/libstdc++.so.6\r\n#8  0x0000000000ff265c in CArchive::operator>>(std::string&) ()\r\n#9  0x0000000000e6fb6f in CFileItemList::Archive(CArchive&) ()\r\n#10 0x0000000000ff19ff in CArchive::operator>>(IArchivable&) ()\r\n#11 0x0000000000e67bb3 in CFileItemList::Load(int) ()\r\n#12 0x0000000000f5942f in UPNP::CUPnPServer::OnBrowseDirectChildren(NPT_Reference<PLT_Action>&, char const*, char const*, unsigned int, unsigned int, char const*, PLT_HttpRequestContext const&) ()\r\n```\r\nsize_t is variable sized and if someone copies userdata from a 32-bit to a 64-bit system some string sizes could be quite large as 4 bytes from the string are added onto the size.\r\n\r\nI limited everything to 32bit as we likely won't need large items in our archives, also it seems safest compatibility wise."},"comment":{"url":"https://api.github.com/repos/xbmc/xbmc/issues/comments/231818795","html_url":"https://github.com/xbmc/xbmc/pull/9225#issuecomment-231818795","issue_url":"https://api.github.com/repos/xbmc/xbmc/issues/9225","id":231818795,"user":{"login":"fritsch","id":1089309,"avatar_url":"https://avatars.githubusercontent.com/u/1089309?v=3","gravatar_id":"","url":"https://api.github.com/users/fritsch","html_url":"https://github.com/fritsch","followers_url":"https://api.github.com/users/fritsch/followers","following_url":"https://api.github.com/users/fritsch/following{/other_user}","gists_url":"https://api.github.com/users/fritsch/gists{/gist_id}","starred_url":"https://api.github.com/users/fritsch/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fritsch/subscriptions","organizations_url":"https://api.github.com/users/fritsch/orgs","repos_url":"https://api.github.com/users/fritsch/repos","events_url":"https://api.github.com/users/fritsch/events{/privacy}","received_events_url":"https://api.github.com/users/fritsch/received_events","type":"User","site_admin":false},"created_at":"2016-07-11T18:16:35Z","updated_at":"2016-07-11T18:16:35Z","body":"I don't care about the name too much, but much more about this bugfix. As\nit is technically correct, the name can be easily changed with a follow PR\nby whoever wants.\n\n2016-07-11 10:40 GMT+02:00 Dave Blake <notifications@github.com>:\n\n> CArchive is probably badly named too! Still prefer Milhouse's suggestion,\n> but hey not going to argue over a name. Great to get the cache nuked :)\n>\n> —\n> You are receiving this because you were mentioned.\n> Reply to this email directly, view it on GitHub\n> <https://github.com/xbmc/xbmc/pull/9225#issuecomment-231674431>, or mute\n> the thread\n> <https://github.com/notifications/unsubscribe/ABCfHcdlZo_OuXjk3NJG7XSkDq41eCh8ks5qUgFigaJpZM4HkiqL>\n> .\n>\n\n\n\n-- \n                   Key-ID:     0x1A995A9B\n                   keyserver: pgp.mit.edu\n==============================================================\nFingerprint: 4606 DA19 EC2E 9A0B 0157  C81B DA07 CF63 1A99 5A9B\n"}}
{"actor":{"display_login":"fritsch"}}