diff options
author | George Hazan <ghazan@miranda.im> | 2022-11-18 19:56:08 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2022-11-18 19:56:08 +0300 |
commit | b3061e352adfb4620fe407e59bcbe91d766669b9 (patch) | |
tree | 769fb04993ae7aa55756c3beaa3bcc7542261944 /protocols | |
parent | 2501ef6a104326fe14ad13bf3023ba7a62d2da46 (diff) |
rare crash fix
Diffstat (limited to 'protocols')
-rw-r--r-- | protocols/WhatsApp/src/iq.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/protocols/WhatsApp/src/iq.cpp b/protocols/WhatsApp/src/iq.cpp index 474a54a376..6700b4e04a 100644 --- a/protocols/WhatsApp/src/iq.cpp +++ b/protocols/WhatsApp/src/iq.cpp @@ -97,8 +97,8 @@ void WhatsAppProto::OnIqGetKeys(const WANode &node, void *pUserInfo) m_signalStore.injectSession(it); // don't forget to send delayed message when all keys are retrieved - if (auto *pTask = (WASendTask *)pUserInfo) - SendTask(pTask); + if (pUserInfo != INVALID_HANDLE_VALUE) + SendTask((WASendTask *)pUserInfo); } ///////////////////////////////////////////////////////////////////////////////////////// @@ -122,7 +122,7 @@ void WhatsAppProto::OnIqGetUsync(const WANode &node) pKey->addChild("user")->addAttr("jid", it->toString()); } if (pKey->getChildren().getCount() > 0) - WSSendNode(iq, &WhatsAppProto::OnIqGetKeys, nullptr); + WSSendNode(iq, &WhatsAppProto::OnIqGetKeys, INVALID_HANDLE_VALUE); } } |