{"action":"created","issue":{"url":"https://api.github.com/repos/irungentoo/toxcore/issues/1310","labels_url":"https://api.github.com/repos/irungentoo/toxcore/issues/1310/labels{/name}","comments_url":"https://api.github.com/repos/irungentoo/toxcore/issues/1310/comments","events_url":"https://api.github.com/repos/irungentoo/toxcore/issues/1310/events","html_url":"https://github.com/irungentoo/toxcore/issues/1310","id":65109154,"number":1310,"title":"Tox fails when run through torsocks","user":{"login":"yurivict","id":271906,"avatar_url":"https://avatars.githubusercontent.com/u/271906?v=3","gravatar_id":"","url":"https://api.github.com/users/yurivict","html_url":"https://github.com/yurivict","followers_url":"https://api.github.com/users/yurivict/followers","following_url":"https://api.github.com/users/yurivict/following{/other_user}","gists_url":"https://api.github.com/users/yurivict/gists{/gist_id}","starred_url":"https://api.github.com/users/yurivict/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yurivict/subscriptions","organizations_url":"https://api.github.com/users/yurivict/orgs","repos_url":"https://api.github.com/users/yurivict/repos","events_url":"https://api.github.com/users/yurivict/events{/privacy}","received_events_url":"https://api.github.com/users/yurivict/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":12,"created_at":"2015-03-30T00:02:22Z","updated_at":"2015-05-11T03:05:19Z","closed_at":null,"body":"When UDP option is checked in client, tox crashes (tox==null). It starts when UDP traffic is sent and lost, but when torsocks explicitly fails socket(2) calls it crashes silently. It should say \"Unable to create UDP socket\", and exit gracefully.\r\n\r\nSteps to reproduce:\r\n* Install torsocks from here https://github.com/dgoulet/torsocks/\r\n* Have tor running\r\n* Choose option 'Enable UDP' in client (I use qTox)\r\n* Run 'torsocks qTox'\r\n* Observe it crash"},"comment":{"url":"https://api.github.com/repos/irungentoo/toxcore/issues/comments/100751697","html_url":"https://github.com/irungentoo/toxcore/issues/1310#issuecomment-100751697","issue_url":"https://api.github.com/repos/irungentoo/toxcore/issues/1310","id":100751697,"user":{"login":"adcreare","id":10427390,"avatar_url":"https://avatars.githubusercontent.com/u/10427390?v=3","gravatar_id":"","url":"https://api.github.com/users/adcreare","html_url":"https://github.com/adcreare","followers_url":"https://api.github.com/users/adcreare/followers","following_url":"https://api.github.com/users/adcreare/following{/other_user}","gists_url":"https://api.github.com/users/adcreare/gists{/gist_id}","starred_url":"https://api.github.com/users/adcreare/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adcreare/subscriptions","organizations_url":"https://api.github.com/users/adcreare/orgs","repos_url":"https://api.github.com/users/adcreare/repos","events_url":"https://api.github.com/users/adcreare/events{/privacy}","received_events_url":"https://api.github.com/users/adcreare/received_events","type":"User","site_admin":false},"created_at":"2015-05-11T03:05:19Z","updated_at":"2015-05-11T03:05:19Z","body":"I just had a look at the code in Core::make_tox in core.cpp for qtox. \r\n\r\nNow maybe I'm reading this all wrong (probably very likely) however what I see is that\r\n\r\nstart() calls make_tox \r\n\r\nmake_tox() throws that error you get in one of two places in that function, eitherway its ending up with tox being a nullptr and then it returns. \r\n\r\nstart() never checks after the make_tox to make sure that the tox object actually exists! \r\nI would have expected it would have called isReady() or something but it doesn't it just goes on and starts doing other things. Things that do use the tox object.. So doesn't seem right to me. \r\n\r\nOf course this doesn't explain why tox core isn't starting right but would probably be a good addition to qtox to fail a little more gracefully? \r\n-----------------\r\nReading the code, I was just wondering if maybe the profile has become corrupted? in the proxy area somehow? Have you tried with a clean profile?\r\n "}}