OAuth: Fix crash when closing the browser while identifying
authorOlivier Goffart <ogoffart@woboq.com>
Mon, 25 Sep 2017 14:44:33 +0000 (16:44 +0200)
committerOlivier Goffart <olivier@woboq.com>
Tue, 26 Sep 2017 12:56:57 +0000 (14:56 +0200)
commit7af81f76657aa9aed7b3942484f925b9ac9c2574
treefe9b6c7741495ead1140b75d3fd82446cad7f206
parent278129b286dcbf8849b552d3c55b0a86f8a8bbf0
OAuth: Fix crash when closing the browser while identifying

To reproduce, log in and click "authorize" on the browser, then close
the browser before the client has replied, (but after redirected to localhost,
i.e. when the client is asking the server for the token)

The problem is that socket can be destroyed so we don't need to answer on a
destroyed socket.
src/gui/creds/oauth.cpp