diff options
author | George Hazan <ghazan@miranda.im> | 2022-11-17 20:55:18 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2022-11-17 20:55:18 +0300 |
commit | a55799c07bc5d1fddd51f22683710d31c19376cd (patch) | |
tree | de6cb3ba898554e23656c3a3ed0978c802f65b15 /protocols/WhatsApp/src/utils.h | |
parent | 6d4ab3925c39c234cefd6b6145eb98c169693681 (diff) |
WhatsApp: user's key retrieving
Diffstat (limited to 'protocols/WhatsApp/src/utils.h')
-rw-r--r-- | protocols/WhatsApp/src/utils.h | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/protocols/WhatsApp/src/utils.h b/protocols/WhatsApp/src/utils.h index 37e48793b2..d55e816d8c 100644 --- a/protocols/WhatsApp/src/utils.h +++ b/protocols/WhatsApp/src/utils.h @@ -172,6 +172,30 @@ struct WAJid }; ///////////////////////////////////////////////////////////////////////////////////////// +// WASendTask + +struct WASendTask +{ + WASendTask(const char *jid) : + payLoad("message"), + arDest(1) + { + __int64 msgId; + Utils_GetRandom(&msgId, sizeof(msgId)); + if (msgId < 0) + msgId = -msgId; + _i64toa(msgId, szMsgId, 10); + + payLoad << CHAR_PARAM("id", szMsgId) << CHAR_PARAM("type", "text") << CHAR_PARAM("to", jid); + } + + char szMsgId[40]; + WANode payLoad; + OBJLIST<WAJid> arDest; + MBinBuffer content; +}; + +///////////////////////////////////////////////////////////////////////////////////////// // LT_HASH struct LT_HASH |