diff options
author | George Hazan <ghazan@miranda.im> | 2022-11-15 20:47:19 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2022-11-15 20:47:19 +0300 |
commit | abbec7be53ade1d599d1c02f91b03e2f66d82f33 (patch) | |
tree | e4798b9e12e835a727de486cffded4b3ae4465e7 /protocols | |
parent | dc0a59b619ed0959e3e2b6c58664fd044d07b0b2 (diff) |
WhatsApp: fix for negative message ids
Diffstat (limited to 'protocols')
-rw-r--r-- | protocols/WhatsApp/src/message.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/protocols/WhatsApp/src/message.cpp b/protocols/WhatsApp/src/message.cpp index e82cef0334..df272eb0b0 100644 --- a/protocols/WhatsApp/src/message.cpp +++ b/protocols/WhatsApp/src/message.cpp @@ -366,6 +366,8 @@ int WhatsAppProto::SendTextMessage(const char *jid, const char *pszMsg) char szMsgId[40]; __int64 msgId; Utils_GetRandom(&msgId, sizeof(msgId)); + if (msgId < 0) + msgId = -msgId; _i64toa(msgId, szMsgId, 10); // mother node for all participants |