{"action":"created","issue":{"url":"https://api.github.com/repos/qTox/qTox/issues/5117","repository_url":"https://api.github.com/repos/qTox/qTox","labels_url":"https://api.github.com/repos/qTox/qTox/issues/5117/labels{/name}","comments_url":"https://api.github.com/repos/qTox/qTox/issues/5117/comments","events_url":"https://api.github.com/repos/qTox/qTox/issues/5117/events","html_url":"https://github.com/qTox/qTox/issues/5117","id":319698838,"number":5117,"title":"GroupChatForm::updateUserNames index out of range access","user":{"login":"anthonybilinski","id":10469203,"avatar_url":"https://avatars1.githubusercontent.com/u/10469203?v=4","gravatar_id":"","url":"https://api.github.com/users/anthonybilinski","html_url":"https://github.com/anthonybilinski","followers_url":"https://api.github.com/users/anthonybilinski/followers","following_url":"https://api.github.com/users/anthonybilinski/following{/other_user}","gists_url":"https://api.github.com/users/anthonybilinski/gists{/gist_id}","starred_url":"https://api.github.com/users/anthonybilinski/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/anthonybilinski/subscriptions","organizations_url":"https://api.github.com/users/anthonybilinski/orgs","repos_url":"https://api.github.com/users/anthonybilinski/repos","events_url":"https://api.github.com/users/anthonybilinski/events{/privacy}","received_events_url":"https://api.github.com/users/anthonybilinski/received_events","type":"User","site_admin":false},"labels":[{"id":109351124,"url":"https://api.github.com/repos/qTox/qTox/labels/I-bug","name":"I-bug","color":"fc2929","default":false},{"id":250826568,"url":"https://api.github.com/repos/qTox/qTox/labels/I-crash","name":"I-crash","color":"fc2929","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-05-02T20:23:34Z","updated_at":"2018-05-02T20:37:33Z","closed_at":null,"author_association":"MEMBER","body":"##### Brief Description\r\n\r\nOS: Ubuntu 16.04\r\nqTox version: v1.14.1+\r\nCommit hash:  498c04ba50e91ff183b593ec3cebe381bde215a4\r\ntoxcore:  0.2.2\r\nQt:  5.5.1\r\n\r\nReproducible: Rarely\r\n\r\n##### Steps to reproduce\r\n\r\n1. Have someone join group while updateUserNames is already running.\r\n\r\n##### Observed Behavior\r\nWe make a vector of name labels of length `group->getPeersCount()` but then iterate over all names `group->getPeerList()`. If these two are different sizes, we try to insert a label past the end of `nickLabelList`\r\n\r\n```\r\n(gdb) bt\r\n#0  0x00007ffff1460428 in __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:54\r\n#1  0x00007ffff146202a in __GI_abort () at abort.c:89\r\n#2  0x00007ffff1e26f81 in QMessageLogger::fatal(char const*, ...) const () from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5\r\n#3  0x00007ffff1e22151 in qt_assert_x(char const*, char const*, char const*, int) () from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5\r\n#4  0x0000000000765f5e in QVector<QLabel*>::operator[] (this=0x7fffffffca00, i=19) at /usr/include/x86_64-linux-gnu/qt5/QtCore/qvector.h:401\r\n#5  0x00000000007636be in GroupChatForm::updateUserNames (this=0x3e6b730) at /home/abilinski/build/qTox/src/widget/form/groupchatform.cpp:258\r\n#6  0x0000000000762c57 in GroupChatForm::onUserListChanged (this=0x3e6b730) at /home/abilinski/build/qTox/src/widget/form/groupchatform.cpp:170\r\n\r\n(gdb) p peerNumber\r\n$1 = 20\r\n(gdb) p peersCount\r\n$2 = 19\r\n(gdb) p names.size()\r\n$3 = 20\r\n\r\n##### Expected Behavior\r\nnot crash :D"},"comment":{"url":"https://api.github.com/repos/qTox/qTox/issues/comments/386112821","html_url":"https://github.com/qTox/qTox/issues/5117#issuecomment-386112821","issue_url":"https://api.github.com/repos/qTox/qTox/issues/5117","id":386112821,"user":{"login":"anthonybilinski","id":10469203,"avatar_url":"https://avatars1.githubusercontent.com/u/10469203?v=4","gravatar_id":"","url":"https://api.github.com/users/anthonybilinski","html_url":"https://github.com/anthonybilinski","followers_url":"https://api.github.com/users/anthonybilinski/followers","following_url":"https://api.github.com/users/anthonybilinski/following{/other_user}","gists_url":"https://api.github.com/users/anthonybilinski/gists{/gist_id}","starred_url":"https://api.github.com/users/anthonybilinski/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/anthonybilinski/subscriptions","organizations_url":"https://api.github.com/users/anthonybilinski/orgs","repos_url":"https://api.github.com/users/anthonybilinski/repos","events_url":"https://api.github.com/users/anthonybilinski/events{/privacy}","received_events_url":"https://api.github.com/users/anthonybilinski/received_events","type":"User","site_admin":false},"created_at":"2018-05-02T20:37:33Z","updated_at":"2018-05-02T20:37:33Z","author_association":"MEMBER","body":"Note that I only hit this crash when adding lots of logs into group->getPeerList() and maybe stopping the program for a minute with gdb, which would would effect timing constraints and may be the trigger, but it's still an underlying synchronization problem."}}
{"actor":{"display_login":"anthonybilinski"}}