summaryrefslogtreecommitdiff
path: root/protocols/Discord
diff options
context:
space:
mode:
authorGeorge Hazan <ghazan@miranda.im>2018-03-04 18:12:17 +0300
committerGeorge Hazan <ghazan@miranda.im>2018-03-04 18:12:24 +0300
commit698930dd28f2072d36f70efecfec32c7042c8016 (patch)
treead4136f591f67e5f270c756b80c981eba45b233b /protocols/Discord
parent91b02805d2e9b08d4eb29e1f67bf8b7d627ca45f (diff)
fixes #1173 (random crash on a fresh Discord account)
Diffstat (limited to 'protocols/Discord')
-rw-r--r--protocols/Discord/src/gateway.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/protocols/Discord/src/gateway.cpp b/protocols/Discord/src/gateway.cpp
index 480cf6c012..ffd66f6d0a 100644
--- a/protocols/Discord/src/gateway.cpp
+++ b/protocols/Discord/src/gateway.cpp
@@ -356,6 +356,11 @@ void CDiscordProto::GatewaySendHeartbeat()
void CDiscordProto::GatewaySendIdentify()
{
+ if (m_szAccessToken == nullptr) {
+ ConnectionFailed(LOGINERR_WRONGPASSWORD);
+ return;
+ }
+
wchar_t wszOs[256];
GetOSDisplayString(wszOs, _countof(wszOs));